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

[cpp] avoid null pointer deference in PhysicsConstraintTimeline #2694

Open
wants to merge 1 commit into
base: 4.2
Choose a base branch
from

Conversation

bendmorris
Copy link

Compiling spine-cpp with mingw and -Werror results in:

/home/ben/Dev/march/krit/spine-runtimes/spine-cpp/spine-cpp/src/spine/PhysicsConstraintTimeline.cpp:98:75: error: ‘this’ pointer is null [-Werror=nonnull]
   98 |                                 if (constraint->_active) constraint->reset();
      | 

This looks like a real issue as constraint is definitely null here. The intent seems pretty clear though so here's a quick fix - feel free to throw it away and fix it a different way.

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

Successfully merging this pull request may close these issues.

1 participant