mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 19:08:55 -04:00
prevent crash, return sensible value from find_type()
This commit is contained in:
parent
4af740cebe
commit
f89ef1f257
@ -229,7 +229,7 @@ TypeHandle TypeRegistry::
|
|||||||
find_type(const string &name) const {
|
find_type(const string &name) const {
|
||||||
_lock->lock();
|
_lock->lock();
|
||||||
|
|
||||||
TypeHandle handle;
|
TypeHandle handle = TypeHandle::none();
|
||||||
NameRegistry::const_iterator ri;
|
NameRegistry::const_iterator ri;
|
||||||
ri = _name_registry.find(name);
|
ri = _name_registry.find(name);
|
||||||
if (ri != _name_registry.end()) {
|
if (ri != _name_registry.end()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user