New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deadlock in NVDA Process Injection #4888
Comments
Attachment debug.txt added by camlorn on 2015-02-06 04:08 |
Comment 1 by mdcurran on 2015-02-06 04:29 From your stack I can see that the ig7icd32 module (what ever that is) is running its dllmain function, but inside it, somehow a Windows hook is running. Perhaps that dllmain created a window and sent a message. But the stack around there may not be accurate as the warning states. I don't think that dllmain call is deliberately loading extra dlls, but it is perhaps sending a window message, which is making one of NVDA's windows hooks run. This hook tries to acquire NVDA's inprocThreadsLock. At the same time, possibly due to dllmain creating a window or something, NVDA's winEvent callback is also being run, which as part of it it tries to register more windows hooks and in doing that SetWindowsHookEx tries to increase the refcount on the dl containing the hook (nvdaHelper) by calling GetModuleFileNameEx or something. But as ig7icd32's dllmain is currently running, this call must wait until it finishes. but, it cannot because it is currently also holding inprocThreadsLock. It could be argued that perhaps we should try and figure out a way of not holding the lock at the time we are registering Windows hooks due to a dll load, but it can certainly also be argued that dllmain ina module should not really do any GUI stuff either. |
Comment 2 by mdcurran on 2015-02-06 04:29 |
Comment 3 by camlorn on 2015-02-06 21:28
As far as I can tell, the potential for this is on any graphics card which uses any Intel driver that does this. I believe that a second condition is that the app dynamically load OpenGL; otherwise, the DLL is loaded well before the creation of windows. |
Comment 4 by camlorn on 2015-04-03 22:29 |
Comment 5 by camlorn on 2015-04-04 15:27 |
Comment 6 by camlorn on 2015-07-09 15:32 |
closing as worksforme because it depends on the grafic driver and it is apparently fixed for @camlorn. Feel free to comment if this is not the case and we can reopen it. |
Reported by camlorn on 2015-02-06 04:08
Hi,
So. Let me emphasize that this is a maybe still. A pretty sure maybe, but a maybe nonetheless. Anyhow.
I'm working with Pyglet, a framework for game development in Python. It's OpenGL-based and includes a lot of stuff. Merely importing the modules pyglet and pyglet.app in a Python script causes a deadlock which appears to be in NVDA process injection code. I've attached tracebacks, as the debug log is long.
My question at the moment is this. What events specifically trigger NVDA's injection routines? As far as I can tell, the importing of these modules runs nothing save some dll loading, yet two threads end up going through NVDA. The latter appears to be something to do with the graphics driver. And the end result is a deadlock involving LdrpLoaderLock and inprocThreadsLock, the former of which Google reveals little about and the latter of which is in NVDA.
Any suggestions? I'd love to solve this, as otherwise it's back to maintaining my own package that does less than the one I want to use.
The text was updated successfully, but these errors were encountered: