Browse Source

refine log

pull/196/merge
Max Lv 10 years ago
parent
commit
a772aba1f4
4 changed files with 9 additions and 5 deletions
  1. 4
      src/local.c
  2. 2
      src/redir.c
  3. 4
      src/server.c
  4. 4
      src/tunnel.c

4
src/local.c

@ -541,7 +541,9 @@ static void remote_timeout_cb(EV_P_ ev_timer *watcher, int revents)
struct remote *remote = remote_ctx->remote;
struct server *server = remote->server;
LOGD("remote timeout");
if (verbose) {
LOGD("TCP connection timeout");
}
close_and_free_remote(EV_A_ remote);
close_and_free_server(EV_A_ server);

2
src/redir.c

@ -270,8 +270,6 @@ static void remote_timeout_cb(EV_P_ ev_timer *watcher, int revents)
struct remote *remote = remote_ctx->remote;
struct server *server = remote->server;
LOGD("remote timeout");
ev_timer_stop(EV_A_ watcher);
if (server == NULL) {

4
src/server.c

@ -499,7 +499,9 @@ static void server_timeout_cb(EV_P_ ev_timer *watcher, int revents)
struct server *server = server_ctx->server;
struct remote *remote = server->remote;
LOGE("TCP connection timeout");
if (verbose) {
LOGD("TCP connection timeout");
}
close_and_free_remote(EV_A_ remote);
close_and_free_server(EV_A_ server);

4
src/tunnel.c

@ -275,7 +275,9 @@ static void remote_timeout_cb(EV_P_ ev_timer *watcher, int revents)
struct remote *remote = remote_ctx->remote;
struct server *server = remote->server;
LOGD("remote timeout");
if (verbose) {
LOGD("TCP connection timeout");
}
ev_timer_stop(EV_A_ watcher);

Loading…
Cancel
Save