Skip to content

Commit da32443

Browse files
WelongZuoz00636558
andauthored
Remove TLSCONN_DEBUG dead code in tls.c (valkey-io#1891)
This code is a dead code, there is also a undefined fd error in it. Obviously this will not compile if this kind of debugging is enabled. This seems to be broken ever since 5a47794 which was done in 2019. It's dead code that we never test and never use. Fixes valkey-io#1887 Signed-off-by: WelongZuo <zuowl@qq.com> Co-authored-by: z00636558 <zuowenlong6@huawei.com>
1 parent ea2e48a commit da32443

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

src/tls.c

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -415,12 +415,6 @@ static int tlsConfigure(void *priv, int reconfigure) {
415415
return C_ERR;
416416
}
417417

418-
#ifdef TLS_DEBUGGING
419-
#define TLSCONN_DEBUG(fmt, ...) serverLog(LL_DEBUG, "TLSCONN: " fmt, __VA_ARGS__)
420-
#else
421-
#define TLSCONN_DEBUG(fmt, ...)
422-
#endif
423-
424418
static ConnectionType CT_TLS;
425419

426420
/* Normal socket connections have a simple events/handler correlation.
@@ -697,9 +691,6 @@ static void TLSAccept(void *_conn) {
697691
static void tlsHandleEvent(tls_connection *conn, int mask) {
698692
int ret, conn_error;
699693

700-
TLSCONN_DEBUG("tlsEventHandler(): fd=%d, state=%d, mask=%d, r=%d, w=%d, flags=%d", fd, conn->c.state, mask,
701-
conn->c.read_handler != NULL, conn->c.write_handler != NULL, conn->flags);
702-
703694
switch (conn->c.state) {
704695
case CONN_STATE_CONNECTING:
705696
conn_error = anetGetError(conn->c.fd);

0 commit comments

Comments
 (0)