- I want to make sure it isn't just incidental that the bug isn't surfacing in Trunk
- Am I actually doing something wrong?
- What's the correct way to read a null terminated string from a TStream in 2.0.6 then?
Can you test whether you can reproduce the behaviour if you use a loop instead of a
goto?
I wrote a function for reading null-terminated strings from a TStream.
strlen ? It is in system, so defaults. (As are more C like PChar handling routines)
Also note #0 can be embedded in any true Pascal type string.
This is not a bug in any way.
Thaddy, what nonsense is that again? How should
Superdisk use
strlen when they're reading from a
TStream? They need to read byte by byte until they've found the
NUL-character. And your comment regarding
NUL is irrelevant in this case as well, cause
Superdisk explicitly stated that they need to read a
NUL-terminated string from a stream.
Also it might be a potential bug, because
goto might upset the implicit exception handling.