Commit c04123fa authored by Jeff Latimer's avatar Jeff Latimer Committed by Alexandre Julliard

mpr: Check for out of memory condition.

parent 8d1a8591
......@@ -56,8 +56,9 @@ static LPSTR MPR_GetValueName( LPCSTR pbResource, WORD cbResource, BYTE nType )
DWORD i;
name = HeapAlloc( GetProcessHeap(), 0, 6+cbResource*2 );
if( name )
sprintf( name, "X-%02X-", nType );
if( !name ) return NULL;
sprintf( name, "X-%02X-", nType );
for(i=0; i<cbResource; i++)
{
name[5+i*2]=hex((pbResource[i]&0xf0)>>4);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment