mirror of
https://github.com/gnustep/libs-back.git
synced 2025-02-24 04:11:28 +00:00
Wrap WIN32 server call to windowEventProc with an autorelease pool to avoid holding window surfaces causing memory issues
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/branches/gnustep_testplant_branch@36609 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
16ef33d4c4
commit
5006663d2d
1 changed files with 6 additions and 2 deletions
|
@ -39,6 +39,7 @@
|
|||
#include <Foundation/NSTimer.h>
|
||||
#include <Foundation/NSUserDefaults.h>
|
||||
#include <Foundation/NSException.h>
|
||||
#include <Foundation/NSAutoreleasePool.h>
|
||||
#include <AppKit/AppKitExceptions.h>
|
||||
#include <AppKit/NSApplication.h>
|
||||
#include <AppKit/NSGraphics.h>
|
||||
|
@ -457,7 +458,7 @@ BOOL CALLBACK LoadDisplayMonitorInfo(HMONITOR hMonitor,
|
|||
// MESSAGE PROCESSING!!!!!
|
||||
TranslateMessage(&msg);
|
||||
DispatchMessage(&msg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3319,6 +3320,9 @@ LRESULT CALLBACK MainWndProc(HWND hwnd, UINT uMsg,
|
|||
return (LRESULT)NULL;
|
||||
}
|
||||
|
||||
return [ctxt windowEventProc: hwnd : uMsg : wParam : lParam];
|
||||
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
|
||||
LRESULT status = [ctxt windowEventProc: hwnd : uMsg : wParam : lParam];
|
||||
[pool release];
|
||||
return status;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue