diff options
author | Werner Koch <wk@gnupg.org> | 2008-10-15 15:23:10 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2008-10-15 15:23:10 +0200 |
commit | b519a52ceaff0a6c2b01f1013f8f34b96261f4ad (patch) | |
tree | 1be0050179a8c71753191a00f56b432a2f7e3423 /scd/command.c | |
parent | SCD changes for PC/SC under W32. (diff) | |
download | gnupg2-b519a52ceaff0a6c2b01f1013f8f34b96261f4ad.tar.xz gnupg2-b519a52ceaff0a6c2b01f1013f8f34b96261f4ad.zip |
Made scdaemon more robust on Windows.
Diffstat (limited to 'scd/command.c')
-rw-r--r-- | scd/command.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/scd/command.c b/scd/command.c index aabd93c25..7d2515474 100644 --- a/scd/command.c +++ b/scd/command.c @@ -1,6 +1,6 @@ /* command.c - SCdaemon command handler * Copyright (C) 2001, 2002, 2003, 2004, 2005, - * 2007 Free Software Foundation, Inc. + * 2007, 2008 Free Software Foundation, Inc. * * This file is part of GnuPG. * @@ -1776,8 +1776,9 @@ register_commands (assuan_context_t ctx) /* Startup the server. If FD is given as -1 this is simple pipe - server, otherwise it is a regular server. */ -void + server, otherwise it is a regular server. Returns true if there + are no more active asessions. */ +int scd_command_handler (ctrl_t ctrl, int fd) { int rc; @@ -1872,6 +1873,9 @@ scd_command_handler (ctrl_t ctrl, int fd) /* Release the Assuan context. */ assuan_deinit_server (ctx); + + /* If there are no more sessions return true. */ + return !session_list; } |