From 60502143d226cf463994a09557934340249ece75 Mon Sep 17 00:00:00 2001 From: Dave Hawkes Date: Thu, 28 Feb 2002 21:43:06 +0000 Subject: [PATCH] Fixed winproc memory leak. --- windows/winproc.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/windows/winproc.c b/windows/winproc.c index fd51aab4dc6..706a9449544 100644 --- a/windows/winproc.c +++ b/windows/winproc.c @@ -448,7 +448,15 @@ BOOL WINPROC_SetProc( HWINDOWPROC *pFirst, WNDPROC16 func, if (((*ppPrev)->type == type) && (func == WINPROC_THUNKPROC(*ppPrev))) { - bRecycle = TRUE; + if((*ppPrev)->user == user) + { + bRecycle = TRUE; + } + else + { + WINPROC_FreeProc( *ppPrev, user ); + *ppPrev = NULL; + } break; } }