On Thursday 17 August 2017 12:09:02 Bart via Lazarus wrote: > On 8/17/17, Luca Olivetti via Lazarus <lazarus@lists.lazarus-ide.org> wrote: > > I started using strings as communication buffers since delphi 2. There > > weren't even dynamic arrays then... > > From the Turbo Pascal Help: > > "A string type variable is a sequence of characters ..." > > And then when you click on "characters": > > "Char type > ----------- > Variables of the ordinal type Char are used to store ASCII characters." > > None of this suggests that string is a good type for storing arbitrary > byte sequences. > > You misused an implementation detail of the type (Ansi)String. > And now you blame fpc. > > You should have used a sane type for your buffer from the start. > There was none at the start.
Martin -- _______________________________________________ Lazarus mailing list Lazarus@lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus