mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
Loader: Fixed crash when canceling async loading of model
- Clean up the _loader after we clean up the requests, not before that Signed-off-by: deflected <deflected@users.noreply.github.com>
This commit is contained in:
parent
9bfc425b75
commit
e4a817b469
@ -50,10 +50,10 @@ class Loader(DirectObject):
|
||||
def cancel(self):
|
||||
"Cancels the request. Callback won't be called."
|
||||
if self._loader:
|
||||
self._loader = None
|
||||
for request in self.requests:
|
||||
self._loader.loader.remove(request)
|
||||
del self._loader._requests[request]
|
||||
self._loader = None
|
||||
self.requests = None
|
||||
self.requestList = None
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user