Browse Source

uninitialized variables-persistence

AzaezelX 5 years ago
parent
commit
b6c33bdd2b

+ 2 - 2
Engine/source/persistence/taml/json/tamlJSONParser.h

@@ -38,7 +38,7 @@
 class TamlJSONParser : public TamlParser
 {
 public:
-    TamlJSONParser() {}
+    TamlJSONParser() :mDocumentDirty(false) {}
     virtual ~TamlJSONParser() {}
 
     /// Whether the parser can change a property or not.
@@ -54,4 +54,4 @@ private:
     bool mDocumentDirty;
 };
 
-#endif // _TAML_JSONPARSER_H_
+#endif // _TAML_JSONPARSER_H_

+ 1 - 0
Engine/source/persistence/taml/taml.cpp

@@ -140,6 +140,7 @@ ImplementEnumType(_TamlFormatMode,
 
    // The string-table-entries are set to string literals below because Taml is used in a static scope and the string-table cannot currently be used like that.
    Taml::Taml() :
+      mMasterNodeId(0),
       mFormatMode(XmlFormat),
       mJSONStrict(true),
       mBinaryCompression(true),

+ 1 - 1
Engine/source/persistence/taml/xml/tamlXmlParser.h

@@ -38,7 +38,7 @@
 class TamlXmlParser : public TamlParser
 {
 public:
-    TamlXmlParser() {}
+    TamlXmlParser() :mDocumentDirty(false) {}
     virtual ~TamlXmlParser() {}
 
     /// Whether the parser can change a property or not.