here's my results thus far and the code to produce it
i'm reproduced the bug twice.
Lres - 820046
what would normally be the error text - 288
--
2nd run -
820042
367
(this saved 82004 to the text file)
if (Lres != LUA_YIELD && Lres != 0) {
char buffer[20];
sprintf(buffer,"%i",Lres);
script_console_add_line(buffer);
script_console_add_line( lua_tostring( Lt, -1 ) );
FILE *pFile = fopen ("A/myfile.txt","a");
fwrite (buffer,1,sizeof(buffer),pFile);
fclose (pFile);
it should be noted that when i run the following code it errors properly, Lres returning 2 and saving it to the text file.
This is the code for my demo bug -
function failFn()
print(math.abs("NaN"))
end
failFn();