Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
20th January 2019, 01:50 | #11 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Fixed, sorry.
If size specifier is wrong then gets only first four bytes (half of __int64 start, bytes 0 to 3) from stack for vsprintf start arg, vsprintf count would come from 2nd half (4 bytes, bytes 4 to 7) of start, so count on stack would NOT be accessed at all. EDIT: for other readers, the vsprintf mentioned stuff, think Wonkey is using something like this Code:
int __cdecl dprintf(char* fmt, ...) { char printString[2048]="WonkeyWilly: "; // Must be nul Termed, eg "Test: " or "" char *p=printString; for(;*p++;); --p; // @ null term va_list argp; va_start(argp, fmt); vsprintf(p, fmt, argp); va_end(argp); for(;*p++;); --p; // @ null term if(printString == p || p[-1] != '\n') { p[0]='\n'; // append n/l if not there already p[1]='\0'; } OutputDebugString(printString); return int(p-printString); // strlen printString } Quote:
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 20th January 2019 at 19:29. |
|
|
|