mirror of
https://github.com/UberGames/lilium-voyager.git
synced 2024-12-13 13:40:56 +00:00
Fix SkipRestOfLine going past end of string
If string data starts with a 0 (string terminator), don't skip over it at p++. Not causing any problems in ioq3 as far as I know.
This commit is contained in:
parent
95b241b8ba
commit
5c1091b414
1 changed files with 4 additions and 0 deletions
|
@ -600,6 +600,10 @@ void SkipRestOfLine ( char **data ) {
|
|||
int c;
|
||||
|
||||
p = *data;
|
||||
|
||||
if ( !*p )
|
||||
return;
|
||||
|
||||
while ( (c = *p++) != 0 ) {
|
||||
if ( c == '\n' ) {
|
||||
com_lines++;
|
||||
|
|
Loading…
Reference in a new issue