From: pk910 Date: Thu, 26 Jul 2012 15:20:13 +0000 (+0200) Subject: added output limit for cmd_history X-Git-Tag: v5.4~6 X-Git-Url: http://git.pk910.de/?p=NeonServV5.git;a=commitdiff_plain;h=9f01ca7c6136234eb82c5598394b328e1ba64d71 added output limit for cmd_history --- diff --git a/src/modules/NeonHelp.mod/cmd_neonhelp_history.c b/src/modules/NeonHelp.mod/cmd_neonhelp_history.c index 2378d5a..208418a 100644 --- a/src/modules/NeonHelp.mod/cmd_neonhelp_history.c +++ b/src/modules/NeonHelp.mod/cmd_neonhelp_history.c @@ -58,7 +58,7 @@ CMD_BIND(neonhelp_cmd_history) { } struct Table *table; char *match_str = escape_string(argv[0]); - printf_mysql_query("SELECT `id`, `nick`, `hand`, `host`, `time`, `text`, `status`, `supporter`, `users`.`user_user`, MD5(CONCAT(`id`, `host`, `time`, `supporter`)) FROM `helpserv_requests` LEFT JOIN `users` ON `supporter` = `user_id` WHERE `botid` = '%d' AND (`host` LIKE '%%%s%%' OR `hand` LIKE '%%%s%%' OR `nick` LIKE '%%%s%%') ORDER BY `time` ASC", client->clientid, match_str, match_str, match_str); + printf_mysql_query("SELECT `id`, `nick`, `hand`, `host`, `time`, `text`, `status`, `supporter`, `users`.`user_user`, MD5(CONCAT(`id`, `host`, `time`, `supporter`)) FROM `helpserv_requests` LEFT JOIN `users` ON `supporter` = `user_id` WHERE `botid` = '%d' AND (`host` LIKE '%%%s%%' OR `hand` LIKE '%%%s%%' OR `nick` LIKE '%%%s%%') ORDER BY `time` ASC LIMIT 100", client->clientid, match_str, match_str, match_str); res = mysql_use(); table = table_init(6, mysql_num_rows(res)*3 + 1, 0); table->col_flags[1] |= TABLE_FLAG_COL_SKIP_NULL;