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

fix: nullptr crashes in PetComponent AddDrainImaginationTimer and Deactivate #1639

Merged
merged 1 commit into from
Oct 27, 2024

Conversation

EmosewaMC
Copy link
Collaborator

Resolves an issue where item is null but is accessed but not doing that code and instead consulting the EntityManager for a valid Entity, alongside nullifying the m_Owner objectID should the pet be destroyed and timer still exist.

aronwk-aaron
aronwk-aaron previously approved these changes Oct 27, 2024
Resolves an issue where item is null but is accessed but not doing that code and instead consulting the EntityManager for a valid Entity, alongside nullifying the m_Owner objectID should the pet be destroyed and timer still exist.

Update PetComponent.cpp

Add nullptr check

Add back timer

Update PetComponent.cpp

speculative fix for a different crash

Why are we accessing something before checking if its null
@EmosewaMC EmosewaMC changed the title fix: AddDrainImaginationTimer crashing due to nullptr access fix: nullptr crashes in PetComponent AddDrainImaginationTimer and Deactivate Oct 27, 2024
@EmosewaMC EmosewaMC requested a review from jadebenn October 27, 2024 07:15
@DarwinAnim8or DarwinAnim8or merged commit bfe6900 into main Oct 27, 2024
4 checks passed
@jadebenn jadebenn deleted the FixPetCrash branch November 18, 2024 03:12
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.

3 participants