- avoid using plain char pointers to store script data for FraggleScript.

This commit is contained in:
Christoph Oelckers 2020-04-11 12:12:22 +02:00
commit 3db56651f4
11 changed files with 37 additions and 44 deletions

View file

@ -709,10 +709,10 @@ void FParser::ErrorMessage(FString msg)
int linenum = 0;
// find the line number
if(Rover >= Script->data && Rover <= Script->data+Script->len)
if(Rover >= Script->Data.Data() && Rover <= Script->Data.Data() +Script->len)
{
char *temp;
for(temp = Script->data; temp<LineStart; temp++)
for(temp = Script->Data.Data(); temp<LineStart; temp++)
if(*temp == '\n') linenum++; // count EOLs
}