I encountered problem with the following and made a suggestion:
function TProtoBufInput.readString: AnsiString;
var size: integer;
begin
size := readRawVarint32;
Assert(size > 0, ProtoBufException + 'readString (size <= 0)'); //<--- sometimes, server will pass an empty string and it will cause exception. should change it to Size >= 0 instead.
SetString(result, FBuffer + FPos, size);
Inc(FPos, size);
end;
Seems, the author of this project won't respond to feeback anymore. This project seems dead!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Денис, спасибо за найденную ошибку, в ближайшее время постараюсь исправить эту проблему.
Извини, не сильно часто просматриваю свою почту.
С уважением, Марат
Denis, thanks for the error found, in the near future I will try to fix this problem.
Sorry, I do not often look at my mail.
Sincerely, Marat
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I encountered problem with the following and made a suggestion:
function TProtoBufInput.readString: AnsiString;
var size: integer;
begin
size := readRawVarint32;
Assert(size > 0, ProtoBufException + 'readString (size <= 0)'); //<--- sometimes, server will pass an empty string and it will cause exception. should change it to Size >= 0 instead.
SetString(result, FBuffer + FPos, size);
Inc(FPos, size);
end;
Seems, the author of this project won't respond to feeback anymore. This project seems dead!
Денис, спасибо за найденную ошибку, в ближайшее время постараюсь исправить эту проблему.
Извини, не сильно часто просматриваю свою почту.
С уважением, Марат
Denis, thanks for the error found, in the near future I will try to fix this problem.
Sorry, I do not often look at my mail.
Sincerely, Marat