fixed cmd_search: used wrong MYSQL_RES variable
authorpk910 <philipp@zoelle1.de>
Sun, 11 Dec 2011 06:31:34 +0000 (07:31 +0100)
committerpk910 <philipp@zoelle1.de>
Sun, 11 Dec 2011 06:31:34 +0000 (07:31 +0100)
src/cmd_neonserv_search.c

index 35128ef66193fcaf66c8f810c659d397b2bfd4a0..2101cd2b46443d264c59c17046004cec500fa94b 100644 (file)
@@ -127,7 +127,7 @@ CMD_BIND(neonserv_cmd_search) {
         if(criteria->unvisited) {
             printf_mysql_query("SELECT `chanuser_seen` FROM `chanusers` WHERE `chanuser_cid` = '%s' ORDER BY `chanuser_seen` DESC LIMIT 1", row[5]);
             res2 = mysql_use();
-            row2 = mysql_fetch_row(res);
+            row2 = mysql_fetch_row(res2);
             if(!row2) continue;
             if((time(0) - atoi(row2[0])) < criteria->unvisited) continue;
         }