user32: Don't try to free a handle with a value of 1, which is the dde handle value for asynchronous operations.

This commit is contained in:
James Hawkins 2010-01-04 17:47:02 -08:00 committed by Alexandre Julliard
parent f10d56088e
commit 289047c735
1 changed files with 5 additions and 0 deletions

View File

@ -1468,6 +1468,11 @@ BOOL WINAPI DdeUnaccessData(HDDEDATA hData)
BOOL WINAPI DdeFreeDataHandle(HDDEDATA hData)
{
TRACE("(%p)\n", hData);
/* 1 is the handle value returned by an asynchronous operation. */
if (hData == (HDDEDATA)1)
return TRUE;
return GlobalFree(hData) == 0;
}