mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
parent
f98c14c290
commit
1c357f32ca
@ -497,8 +497,7 @@ make_directory_full(const Filename &filename) {
|
|||||||
// Now make the last one, and check the return value.
|
// Now make the last one, and check the return value.
|
||||||
PT(VirtualFile) result = do_get_file(filename, OF_make_directory);
|
PT(VirtualFile) result = do_get_file(filename, OF_make_directory);
|
||||||
_lock.unlock();
|
_lock.unlock();
|
||||||
nassertr_always(result != nullptr, false);
|
return (result != nullptr) ? result->is_directory() : false;
|
||||||
return result->is_directory();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -133,10 +133,16 @@ set_root(const Filename &root) {
|
|||||||
delete _index;
|
delete _index;
|
||||||
_index = new BamCacheIndex;
|
_index = new BamCacheIndex;
|
||||||
_index_stale_since = 0;
|
_index_stale_since = 0;
|
||||||
|
|
||||||
|
if (!vfs->is_directory(_root)) {
|
||||||
|
util_cat.error()
|
||||||
|
<< "Unable to make directory " << _root << ", caching disabled.\n";
|
||||||
|
_active = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
read_index();
|
read_index();
|
||||||
check_cache_size();
|
check_cache_size();
|
||||||
|
|
||||||
nassertv(vfs->is_directory(_root));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user