--- a/sources/interface.cpp Tue Dec 16 00:05:27 2014 +0200 +++ b/sources/interface.cpp Tue Dec 16 00:15:44 2014 +0200 @@ -29,6 +29,7 @@ */ #include <string.h> +#include <time.h> #include "interface.h" #include "network/rconsession.h" #include "network/ipaddress.h" @@ -916,6 +917,17 @@ continue; } + if (g_output[g_output.size() - 1].length() == 0) + { + time_t now; + time (&now); + char timestamp[32]; + strftime (timestamp, sizeof timestamp, "[%H:%M:%S] ", localtime (&now)); + + for (char* cp = timestamp; *cp != '\0'; ++cp) + g_output[g_output.size() - 1].add_char (*cp); + } + g_output[g_output.size() - 1].add_char (ch); }