Prettified error messages, first work on Util::Config server helpers.

This commit is contained in:
Thulinma 2014-01-22 23:47:59 +01:00
parent c6f63dfb95
commit 5c0f053006
25 changed files with 1254 additions and 327 deletions

View file

@ -1,4 +1,5 @@
#include "dtsc.h"
#include "defines.h"
/// Retrieves a short in network order from the pointer p.
static short btohs(char * p){
@ -269,7 +270,7 @@ namespace DTSC {
void Track::update(JSON::Value & pack){
if (pack["time"].asInt() < lastms){
std::cerr << "Received packets for track " << trackID << " in wrong order (" << pack["time"].asInt() << " < " << lastms << ") - ignoring!" << std::endl;
DEBUG_MSG(DLVL_WARN, "Received packets for track %d in wrong order (%d < %d) - ignoring!", (int)trackID, (int)pack["time"].asInt(), (int)lastms);
return;
}
Part newPart;