]> git.stg.codes - stg.git/blobdiff - projects/stargazer/plugins/store/mysql/mysql_store.cpp
Include MODULE_SETTINGS definition in rpcconfig.h
[stg.git] / projects / stargazer / plugins / store / mysql / mysql_store.cpp
index fefadd5cb803b4b734303fd78b9541fb705d7a80..59e7e3e8189d557fc8a6261d26b246d7ff9f07d4 100644 (file)
@@ -118,7 +118,7 @@ public:
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
-BASE_STORE * GetStore()
+STORE * GetStore()
 {
 return msc.GetStore();
 }
@@ -711,6 +711,13 @@ if (!(res=mysql_store_result(sock)))
     return -1;
 }
 
+if (mysql_num_rows(res) != 1)
+{
+    errorStr = "User not found";
+    mysql_close(sock);
+    return -1;
+}
+
 row = mysql_fetch_row(res);
 
 string param;