From a9c12d0f6fce03d2bf0ca39d83bc6d2d4f2be0b3 Mon Sep 17 00:00:00 2001 From: KrazyIvan Date: Fri, 23 Jan 2015 20:27:19 +0800 Subject: [PATCH] output bugs fix bug: initialize ciphers... (null) listening at (null):8388 --- src/server.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/server.c b/src/server.c index 6687fa8d..abc1b7e8 100644 --- a/src/server.c +++ b/src/server.c @@ -1145,6 +1145,10 @@ int main(int argc, char **argv) exit(EXIT_FAILURE); } + if (method == 0) { + method = "table"; + } + if (timeout == NULL) { timeout = "60"; } @@ -1219,7 +1223,7 @@ int main(int argc, char **argv) FATAL("listen() error"); } setnonblocking(listenfd); - LOGI("listening at %s:%s", host, server_port); + LOGI("listening at %s:%s", host?host:"", server_port); struct listen_ctx *listen_ctx = &listen_ctx_list[index];