fixed small "uninitialized string" bug in bot_NeonHelp.c
authorpk910 <philipp@zoelle1.de>
Sat, 7 Jan 2012 19:07:29 +0000 (20:07 +0100)
committerpk910 <philipp@zoelle1.de>
Sat, 7 Jan 2012 19:07:29 +0000 (20:07 +0100)
src/bot_NeonHelp.c

index 4a8e5a45af896d3b8543cba194df7ebdd54891d3..a5eddd68b38ea31a6ad4e9def216a8ca93893a52 100644 (file)
@@ -391,7 +391,8 @@ static void destroy_support_request(struct ClientSocket *client, struct NeonHelp
             helpnode->log[i] = NULL;
         }
         free(helpnode->log);
-    }
+    } else
+        logbuff[0] = '\0';
     printf_long_mysql_query(1024 + len, "UPDATE `helpserv_requests` SET `status`='2', `log` = CONCAT(`log`, '%s') WHERE `id` = %d", escape_string(logbuff), helpnode->suppid);
     if(do_reply) {
         reply(client, helpnode->user, "NH_DELETED", helpnode->suppid);