Skip to content

Commit

Permalink
Move static NameSpace::GLOBAL definition in static.cpp to avoid 'stat…
Browse files Browse the repository at this point in the history
…ic initialization fiasco' (fixes various Coverity warnings)
  • Loading branch information
rouault committed Nov 19, 2023
1 parent b124309 commit d1314c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 4 additions & 0 deletions src/iso19111/static.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ NS_PROJ_START

// ---------------------------------------------------------------------------

const NameSpaceNNPtr NameSpace::GLOBAL(NameSpace::createGLOBAL());

// ---------------------------------------------------------------------------

/** \brief Key to set the authority citation of a metadata::Identifier.
*
* The value is to be provided as a string or a metadata::Citation.
Expand Down
4 changes: 0 additions & 4 deletions src/iso19111/util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -494,10 +494,6 @@ NameSpaceNNPtr NameSpace::createGLOBAL() {

// ---------------------------------------------------------------------------

const NameSpaceNNPtr NameSpace::GLOBAL(NameSpace::createGLOBAL());

// ---------------------------------------------------------------------------

//! @cond Doxygen_Suppress
struct LocalName::Private {
NameSpacePtr scope{};
Expand Down

0 comments on commit d1314c0

Please sign in to comment.