From 094aa2589e3920d400be93ae2823a6c4b23db623 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Fri, 7 Mar 2014 09:46:44 +0100 Subject: w32: Silence warnings about unused vars. * agent/gpg-agent.c (main) [W32]: Mark unused vars. * sm/gpgsm.c (run_protect_tool) [W32]: Ditto. * g10/trustdb.c (check_regexp) [DISABLE_REGEX]: Ditto. * scd/scdaemon.c (main) [W32]: Ditto. (handle_connections) [W32]: Ditto. (handle_signal) [W32]: Do not build the function at all. * scd/apdu.c (pcsc_send_apdu_direct): Ditto. (connect_pcsc_card): s/long/pcsc_dword_t/. (open_pcsc_reader_direct): Remove var listlen. --- scd/scdaemon.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'scd/scdaemon.c') diff --git a/scd/scdaemon.c b/scd/scdaemon.c index 982c52fec..6fe11f83a 100644 --- a/scd/scdaemon.c +++ b/scd/scdaemon.c @@ -806,7 +806,10 @@ main (int argc, char **argv ) fflush (NULL); -#ifndef HAVE_W32_SYSTEM +#ifdef HAVE_W32_SYSTEM + (void)csh_style; + (void)nodetach; +#else pid = fork (); if (pid == (pid_t)-1) { @@ -958,12 +961,12 @@ scd_get_socket_name () } +#ifndef HAVE_W32_SYSTEM static void handle_signal (int signo) { switch (signo) { -#ifndef HAVE_W32_SYSTEM case SIGHUP: log_info ("SIGHUP received - " "re-reading configuration and resetting cards\n"); @@ -1004,12 +1007,12 @@ handle_signal (int signo) cleanup (); scd_exit (0); break; -#endif /*!HAVE_W32_SYSTEM*/ default: log_info ("signal %d received - no action defined\n", signo); } } +#endif /*!HAVE_W32_SYSTEM*/ static void @@ -1182,7 +1185,6 @@ static void handle_connections (int listen_fd) { npth_attr_t tattr; - int signo; struct sockaddr_un paddr; socklen_t plen; fd_set fdset, read_fdset; @@ -1193,6 +1195,9 @@ handle_connections (int listen_fd) struct timespec curtime; struct timespec timeout; int saved_errno; +#ifndef HAVE_W32_SYSTEM + int signo; +#endif ret = npth_attr_init(&tattr); /* FIXME: Check error. */ -- cgit v1.2.3