summaryrefslogtreecommitdiffstats
path: root/src/core.c
diff options
context:
space:
mode:
authortiptorrent development team <tiptorrent@soleta.eu>2021-09-10 17:50:31 +0200
committertiptorrent development team <tiptorrent@soleta.eu>2021-09-29 15:48:09 +0200
commitb7b410ddc2b84c06801bc2b2320bbeaf7f3fa936 (patch)
treef19aa4b0494abfc5ea90f28aa9e5c76ac50595cd /src/core.c
parentd0c8b24985e365d65cf0ac1a1090858d84c53428 (diff)
extend log on unknown internal state
Specify what client has trigger the unknown internal state
Diffstat (limited to 'src/core.c')
-rw-r--r--src/core.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core.c b/src/core.c
index ef730ac..6c7c542 100644
--- a/src/core.c
+++ b/src/core.c
@@ -168,7 +168,8 @@ static void tip_client_read_cb(struct ev_loop *loop, struct ev_io *io, int event
ev_io_start(loop, &cli->io);
break;
default:
- syslog(LOG_ERR, "unknown read state, critical internal error\n");
+ syslog(LOG_ERR, "unknown read state, critical internal error for %s:%hu\n",
+ inet_ntoa(cli->addr.sin_addr), ntohs(cli->addr.sin_port));
goto close;
}
return;
@@ -268,7 +269,8 @@ static void tip_client_write_cb(struct ev_loop *loop, struct ev_io *io, int even
}
break;
default:
- syslog(LOG_ERR, "unknown write state, critical internal error\n");
+ syslog(LOG_ERR, "unknown write state, critical internal error for %s:%hu\n",
+ inet_ntoa(cli->addr.sin_addr), ntohs(cli->addr.sin_port));
goto close;
}
return;