crfaker fix
Ricky Uy <[email protected]>
| Newsgroups | gmane.comp.graphics.chromium.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, For the Windows version of this library, there should be a call to stubInit() just before the return in DLLMain() in load.c, and all the calls to stubInit() should be removed from the wgl functions in wgl.c. There were several applications that would bail out because of this, including Celestia for Windows. However with this patch, they all work. The problem was that some applications don't call wgl functions before trying to do other things. For example, especially in direct response to Alicia's post, Celestia would try to call ShowWindow() before calling ChoosePixelFormat(). This caused a crash because ShowWindow makes a call to glViewport, and because stubInit() had not yet been called, the glim dispatch table was nulled out. So there was a crash. By having stubInit() in DLLMain, issues like these are resolved. Now there was a comment above DLLMain saying that Windows didn't allow the loading of other libraries in DLLMain, and I'm not sure what has happened since, but it works fine. Hope this helps some people with their applications. Ricky --------------------------------- Do you Yahoo!? New and Improved Yahoo! Mail - Send 10MB messages!