We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb2a830 commit 4189039Copy full SHA for 4189039
openvdb_cmd/vdb_view/Viewer.cc
@@ -189,9 +189,11 @@ init(const std::string& progName, bool background)
189
if (background) {
190
if (sThreadMgr == nullptr) {
191
std::lock_guard<std::mutex> lock(sLock);
192
- OPENVDB_START_THREADSAFE_STATIC_WRITE
193
- sThreadMgr = new ThreadManager;
194
- OPENVDB_FINISH_THREADSAFE_STATIC_WRITE
+ if (sThreadMgr == nullptr) {
+ OPENVDB_START_THREADSAFE_STATIC_WRITE
+ sThreadMgr = new ThreadManager;
195
+ OPENVDB_FINISH_THREADSAFE_STATIC_WRITE
196
+ }
197
}
198
} else {
199
if (sThreadMgr != nullptr) {
0 commit comments