File tree Expand file tree Collapse file tree 2 files changed +9
-10
lines changed
Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -1038,13 +1038,8 @@ class Tree: public TreeBase
10381038 RootNodeType mRoot ; // root node of the tree
10391039 mutable AccessorRegistry mAccessorRegistry ;
10401040 mutable ConstAccessorRegistry mConstAccessorRegistry ;
1041-
1042- static std::unique_ptr<const Name> sTreeTypeName ;
10431041}; // end of Tree class
10441042
1045- template <typename _RootNodeType>
1046- std::unique_ptr<const Name> Tree<_RootNodeType>::sTreeTypeName ;
1047-
10481043
10491044// / @brief Tree3<T, N1, N2>::Type is the type of a three-level tree
10501045// / (Root, Internal, Leaf) with value type T and
@@ -1829,19 +1824,19 @@ template<typename RootNodeType>
18291824inline const Name&
18301825Tree<RootNodeType>::treeType()
18311826{
1832- static std::once_flag once;
1833- std::call_once (once, []()
1827+ static std::string sTreeTypeName = []()
18341828 {
1829+ // @todo use RootNode::NodeChain::foreach() instead
18351830 std::vector<Index> dims;
18361831 Tree::getNodeLog2Dims (dims);
18371832 std::ostringstream ostr;
18381833 ostr << " Tree_" << typeNameAsString<BuildType>();
18391834 for (size_t i = 1 , N = dims.size (); i < N; ++i) { // start from 1 to skip the RootNode
18401835 ostr << " _" << dims[i];
18411836 }
1842- sTreeTypeName . reset ( new Name ( ostr.str ()) );
1843- });
1844- return * sTreeTypeName ;
1837+ return ostr.str ();
1838+ }( );
1839+ return sTreeTypeName ;
18451840}
18461841
18471842
Original file line number Diff line number Diff line change 1+ OpenVDB:
2+ - Bug Fixes:
3+ Fixed a bug when compiling with -fvisibility=hidden and GCC 11 which
4+ would cause a crash in openvdb::initialize()
You can’t perform that action at this time.
0 commit comments