-/* DBHelper.c - NeonServ v5.3
+/* DBHelper.c - NeonServ v5.4
* Copyright (C) 2011-2012 Philipp Kreil (pk910)
*
* This program is free software: you can redistribute it and/or modify
//unregister channel
printf_mysql_query("SELECT `botid`, `channel_name` FROM `bot_channels` LEFT JOIN `channels` ON `chanid` = `channel_id` WHERE `chanid` = '%s' AND `suspended` = '0'", row[1]);
res2 = mysql_use();
- while((row2 = mysql_fetch_row(res))) {
+ while((row2 = mysql_fetch_row(res2))) {
struct ClientSocket *bot;
int clientid = atoi(row2[0]);
for(bot = getBots(SOCKET_FLAG_READY, NULL); bot; bot = getBots(SOCKET_FLAG_READY, bot)) {