DirectPlay should convert dwReserved1/2 registry keys from strings to DWORDs

Frank Richter frank.richter at gmail.com
Sat Mar 3 07:11:32 CST 2007


On 03.03.2007 13:56, Joris Huizer wrote:
> 
>     if( i == 0 )
>     - memcpy( &lpSpData->dwReserved1, returnBuffer,
>     sizeof(lpSpData->dwReserved1) );
>     + sscanf(returnBuffer, "%x", &lpSpData->dwReserved1);
> 
> 
> 
> Couldnt you use:
> strcpy(lpSpData->dwReserved1,returnBuffer);

Reading a string and interpreting it as a hex value, this value then
being stored in a DWORD, is not quite the same as copying the string
into the memory occupied by the DWORD.

-f.r.




More information about the wine-devel mailing list