aboutsummaryrefslogtreecommitdiffstats
path: root/scd/scdaemon.c
diff options
context:
space:
mode:
Diffstat (limited to 'scd/scdaemon.c')
-rw-r--r--scd/scdaemon.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/scd/scdaemon.c b/scd/scdaemon.c
index df1abe8b7..ab2fadbb3 100644
--- a/scd/scdaemon.c
+++ b/scd/scdaemon.c
@@ -1292,8 +1292,7 @@ handle_connections (int listen_fd)
char threadname[50];
npth_t thread;
- snprintf (threadname, sizeof threadname-1, "conn fd=%d", fd);
- threadname[sizeof threadname -1] = 0;
+ snprintf (threadname, sizeof threadname, "conn fd=%d", fd);
ctrl->thread_startup.fd = INT2FD (fd);
ret = npth_create (&thread, &tattr, start_connection_thread, ctrl);
if (ret)