Sfoglia il codice sorgente

oops, clear old _self_compose value

David Rose 23 anni fa
parent
commit
9a898fe061
2 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 1 0
      panda/src/pgraph/renderState.cxx
  2. 1 0
      panda/src/pgraph/transformState.cxx

+ 1 - 0
panda/src/pgraph/renderState.cxx

@@ -692,6 +692,7 @@ clear_cache() {
       if (state->_self_compose != (RenderState *)NULL && 
           state->_self_compose != state) {
         unref_delete((RenderState *)state->_self_compose);
+        state->_self_compose = (RenderState *)NULL;
       }
     }
 

+ 1 - 0
panda/src/pgraph/transformState.cxx

@@ -723,6 +723,7 @@ clear_cache() {
       if (state->_self_compose != (TransformState *)NULL && 
           state->_self_compose != state) {
         unref_delete((TransformState *)state->_self_compose);
+        state->_self_compose = (TransformState *)NULL;
       }
     }