X-Git-Url: https://git.sesse.net/?p=cubemap;a=blobdiff_plain;f=client.cpp;h=28e1f068550e30e8da2492599401d135e2db109b;hp=bb2d26cdcd4abec4516d23ae92142636a33ac341;hb=8f44468bfe4a1d1607b0ab7044c3071605ae1fa7;hpb=4856c49f1b63753ce86ad759ee649a1117628a8e diff --git a/client.cpp b/client.cpp index bb2d26c..28e1f06 100644 --- a/client.cpp +++ b/client.cpp @@ -67,6 +67,7 @@ Client::Client(const ClientProto &serialized, Stream *stream) if (fwmark != 0) { log_perror("setsockopt(SO_MARK)"); } + fwmark = 0; } } @@ -91,7 +92,13 @@ ClientProto Client::serialize() const ClientStats Client::get_stats() const { ClientStats stats; - stats.stream_id = stream_id; + if (stream_id.empty()) { + stats.stream_id = "-"; + } else { + stats.stream_id = stream_id; + } + stats.sock = sock; + stats.fwmark = fwmark; stats.remote_addr = remote_addr; stats.connect_time = connect_time; stats.bytes_sent = bytes_sent;