-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
NPE in finalizer of ProxyObject #894
Comments
Yes it explodes there - why do you think creating a ProxyObject on a NULL dispatch object is a valid case? How is the code reached? My fix would be to raise the NPE from the constructor and be done with that. |
It blows up because the object is already disposed. Notice if dispose is called twice it blows up |
Ok - on first reading I did not realize, that Thanks for reporting this problem |
https://github.com/java-native-access/jna/blob/ea9de70cb73ca0794120666e8ed9794d88ea5c81/contrib/platform/src/com/sun/jna/platform/win32/COM/util/ProxyObject.java line 138
Throws NPE in the finalizer if (Dispatch) this.rawDispatch).getPointer() is null. It tries to call 'equals' on a null reference.
The text was updated successfully, but these errors were encountered: