Return values are reversed in failure/rgdata == NULL case in

GetRegionData (was merge error by me).
This commit is contained in:
Marcus Meissner 2000-10-12 20:39:31 +00:00 committed by Alexandre Julliard
parent 3c5f89522b
commit bcbb6ec92b
1 changed files with 3 additions and 3 deletions

View File

@ -864,10 +864,10 @@ DWORD WINAPI GetRegionData(HRGN hrgn, DWORD count, LPRGNDATA rgndata)
if(count < (size + sizeof(RGNDATAHEADER)) || rgndata == NULL)
{
GDI_ReleaseObj( hrgn );
if (rgndata)
return size + sizeof(RGNDATAHEADER);
else
if (rgndata) /* buffer is too small, signal it by return 0 */
return 0;
else /* user requested buffer size with rgndata NULL */
return size + sizeof(RGNDATAHEADER);
}
rgndata->rdh.dwSize = sizeof(RGNDATAHEADER);