Skip to content
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

Avoid crashing when OpenGL returns NULL from glMapBufferOES() #22

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

rmgrimm
Copy link

@rmgrimm rmgrimm commented Feb 15, 2016

This should resolve issue #19.

Basically, the code is assuming that glMapBufferOES() will always return a valid pointer. The documentation for glMapBufferOES() states instead that null will be returned to signal an error. By ignoring the null case, the underlying OpenGL error results in a complete app crash when memcpy() tries to write data.

Following the OpenGL convention of ignoring commands if an error occurs, this code will ignore any errors that come out of OpenGL. I've dropped a few TODO comments where the code could be further improved. At least it shouldn't crash any longer.

@jasconius
Copy link

I suppose this project is dead, but this is a very valuable PR that makes this pod work just dandy even on new hardware/OS

a shame, since I think this is the best sig capture widget out there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants