Skip to content

Commit

Permalink
* remove COM_Compress() call on script buffer loaded into memory. I a…
Browse files Browse the repository at this point in the history
…ssume

  this was added in order to save cycles if a script is loaded and then
  parsed multiple times, but it caused line numbers to be reported
  incorrectly for parse errors.  If a script is loaded into memory and
  parsed multiple times then the script itself should be optimized instead
  of doing it at runtime.  Also, there was a possibility of segfault
  due to where this was called.
  • Loading branch information
tjdub committed Mar 28, 2008
1 parent 1d072df commit f82ea67
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions code/botlib/l_script.c
Original file line number Diff line number Diff line change
Expand Up @@ -1363,8 +1363,6 @@ script_t *LoadScriptFile(const char *filename)
} //end if
fclose(fp);
#endif
//
script->length = COM_Compress(script->buffer);

return script;
} //end of the function LoadScriptFile
Expand Down

0 comments on commit f82ea67

Please sign in to comment.