port an emufile fix from fceux
This commit is contained in:
parent
15ac34c397
commit
414d661205
|
@ -138,9 +138,14 @@ public:
|
|||
//we dont generate straight into the buffer because it will null terminate (one more byte than we want)
|
||||
int amt = vsnprintf(0,0,format,argptr);
|
||||
char* tempbuf = new char[amt+1];
|
||||
|
||||
va_end(argptr);
|
||||
va_start(argptr, format);
|
||||
vsprintf(tempbuf,format,argptr);
|
||||
|
||||
fwrite(tempbuf,amt);
|
||||
delete[] tempbuf;
|
||||
|
||||
va_end(argptr);
|
||||
return amt;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue