comdlg32: check for overflow before dereferencing (resend)

Sebastian Lackner sebastian at fds-team.de
Sun May 1 10:49:43 CDT 2016


On 01.05.2016 17:30, Pierre Schweitzer wrote:
> -	    while ((lpstrEdit[nStrCharCount]!='"') && (nStrCharCount <= nStrLen))
> +	    while ((nStrCharCount <= nStrLen) && (lpstrEdit[nStrCharCount]!='"'))

The change looks correct, but while you are just it, you might also want to fix
the operator here. It probably should be <, otherwise the loop will also copy
the terminating \0 character. Same for the comparison a couple of lines above.




More information about the wine-devel mailing list