We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1636

Summary: Stack overflow caused by infinite loop and loss of SDL_WindowData
Product: SDL Reporter: Jeff Shanab <jshanab>
Component: videoAssignee: Sam Lantinga <slouken>
Status: RESOLVED ABANDONED QA Contact: Sam Lantinga <slouken>
Severity: major    
Priority: P2 CC: jshanab42, sdlbugs
Version: HG 2.0   
Hardware: x86   
OS: Windows 7   

Description Jeff Shanab 2012-11-08 10:09:22 UTC
I am using SDL in a browser plugin and when resizing in chrome, the call to line 126 in SDL_windowsevents.c gets called over and over again. Somehow the data got lost and null is always returned. Same code works fine on IE and Firefox and may mean the widow handle is undergoing copy construction and the window properties are not moved accross?

LRESULT CALLBACK
WIN_WindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
    SDL_WindowData *data;
    LRESULT returnCode = -1;

    /* Send a SDL_SYSWMEVENT if the application wants them */
    if (SDL_GetEventState(SDL_SYSWMEVENT) == SDL_ENABLE) {
        SDL_SysWMmsg wmmsg;

        SDL_VERSION(&wmmsg.version);
        wmmsg.subsystem = SDL_SYSWM_WINDOWS;
        wmmsg.msg.win.hwnd = hwnd;
        wmmsg.msg.win.msg = msg;
        wmmsg.msg.win.wParam = wParam;
        wmmsg.msg.win.lParam = lParam;
        SDL_SendSysWMEvent(&wmmsg);
    }

    /* Get the window data for the window */
    data = (SDL_WindowData *) GetProp(hwnd, TEXT("SDL_WindowData"));
    if (!data) {
line 126-->        return CallWindowProc(DefWindowProc, hwnd, msg, wParam, lParam);
    }
Comment 1 Sam Lantinga 2012-11-29 00:32:39 UTC
Do you have a section of the call stack so I can see how it's recursing?
What event is it handling?
Comment 2 Jeff Shanab 2012-11-29 06:52:56 UTC
>	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 106 + 0x9 bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	[Frames below may be incorrect and/or missing, no symbols loaded for user32.dll]	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	...
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
.......	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	sdl.dll!WIN_WindowProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam)  Line 646 + 0x1d bytes	C
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	chrome.dll!_DelayedLowerToken@4()  + 0x17e604 bytes	
 	user32.dll!gapfnScSendMessage()  + 0x332 bytes	
 	user32.dll!GetThreadDesktop()  + 0xd7 bytes	
 	user32.dll!GetClientRect()  + 0xc5 bytes	
 	user32.dll!CallWindowProcW()  + 0x1b bytes	
 	The maximum number of stack frames supported by Visual Studio has been exceeded.
Comment 3 Sam Lantinga 2012-11-29 20:45:17 UTC
What is the message being dispatched?

Thanks!
Comment 4 Jeff Shanab 2012-11-30 04:45:33 UTC
It throws an Access Violation on the WinProc but inspecting pointer values shows NULL. I believe this is because no frame was allocated since the  stack was full.

I should also mention that this error occurs when either direct3d or opengl is chosen.

More info. I just modified another library(GLFW) adding a CreatWindowFrom following SDL's example and managed to create the same issue. But when I moved the PollEvents To the top of my display loop such that the swapbuffers did not result in messages attempting to be sent to windows, I got rid of the recursion.

From what I can gather, WindowProp, SetWindowPosition, ShowWindow. and others. all require sending messages to the winproc. IF handling of these messages sends a message, it coulds cause this. 

T thought the stack trace would be sufficient but I realize if we are failing to handle a message and we just keep re-trying, we need one more piece of info. What the message values are. Maybe there is a case where it falls thru to DefWinProc when it should of returned 0.

I will try to print out the message values.
Comment 5 Jeff Shanab 2012-11-30 06:26:03 UTC
The message it is stuck on is WM_PAINT
Comment 6 Ryan C. Gordon 2015-02-18 04:47:12 UTC
*** Bug 1694 has been marked as a duplicate of this bug. ***
Comment 7 Ryan C. Gordon 2018-08-06 21:20:25 UTC
Hello, and sorry if you're getting dozens of copies of this message by email.

We are closing out bugs that appear to be abandoned in some form. This can happen for lots of reasons: we couldn't reproduce it, conversation faded out, the bug was noted as fixed in a comment but we forgot to mark it resolved, the report is good but the fix is impractical, we fixed it a long time ago without realizing there was an associated report, etc.

Individually, any of these bugs might have a better resolution (such as WONTFIX or WORKSFORME or INVALID) but we've added a new resolution of ABANDONED to make this easily searchable and make it clear that it's not necessarily unreasonable to revive a given bug report.

So if this bug is still a going concern and you feel it should still be open: please feel free to reopen it! But unless you respond, we'd like to consider these bugs closed, as many of them are several years old and overwhelming our ability to prioritize recent issues.

(please note that hundred of bug reports were sorted through here, so we apologize for any human error. Just reopen the bug in that case!)

Thanks,
--ryan.