]> git.stg.codes - stg.git/blobdiff - include/stg/user_property.h
Initialize additional members in constructor for PROPERTY
[stg.git] / include / stg / user_property.h
index f0a6d18e85644c8f9d1a8f81919cef898b64f00d..822bc0f90ccdebb93338e7749dc2a5531edd7838 100644 (file)
@@ -173,7 +173,10 @@ template <typename varT>
 inline
 USER_PROPERTY<varT>::USER_PROPERTY(varT & val)
     : value(val),
-      modificationTime(stgTime)
+      modificationTime(stgTime),
+      beforeNotifiers(),
+      afterNotifiers(),
+      mutex()
 {
 pthread_mutex_init(&mutex, NULL);
 }
@@ -363,7 +366,7 @@ std::string filePath = scriptsDir + "/OnChange";
 if (access(filePath.c_str(), X_OK) == 0)
     {
     std::string execString("\"" + filePath + "\" \"" + login + "\" \"" + paramName + "\" \"" + oldValue + "\" \"" + newValue + "\" \"" + admin->GetLogin() + "\" \"" + admin->GetIPStr() + "\"");
-    ScriptExec(execString);
+    ScriptExec(execString.c_str());
     }
 else
     {