Skip to content
Snippets Groups Projects
Commit 1adca0df authored by Shon Ferguson's avatar Shon Ferguson
Browse files

Fixed a reference counting error.

parent f6aa2794
No related branches found
No related tags found
No related merge requests found
......@@ -35,7 +35,7 @@ void NiObject::AddRef() {
void NiObject::SubtractRef() {
--_ref_count;
if ( _ref_count < 1 ) {
if ( _ref_count < 0 ) {
delete this;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment