Skip to content

Commit

Permalink
Moved static initializers into global scope to prevent problems with …
Browse files Browse the repository at this point in the history
…using exit().
  • Loading branch information
robertosfield committed Mar 12, 2012
1 parent df82754 commit 7977b31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/osgViewer/Scene.cpp
Expand Up @@ -18,15 +18,15 @@ using namespace osgViewer;

typedef std::vector< osg::observer_ptr<Scene> > SceneCache;

static SceneCache s_sceneCache;
static SceneCache& getSceneCache()
{
static SceneCache s_sceneCache;
return s_sceneCache;
}

static OpenThreads::Mutex s_sceneCacheMutex;
static OpenThreads::Mutex& getSceneCacheMutex()
{
static OpenThreads::Mutex s_sceneCacheMutex;
return s_sceneCacheMutex;
}

Expand Down

0 comments on commit 7977b31

Please sign in to comment.