[Pkg-gnupg-commit] [libassuan] 23/437: Fixed INPUT/OUTPUT command

Eric Dorland eric at moszumanska.debian.org
Fri May 22 05:33:18 UTC 2015


This is an automated email from the git hooks/post-receive script.

eric pushed a commit to branch master
in repository libassuan.

commit 8bb0195cd405cf518ccfc57d0ed5223939770e01
Author: Werner Koch <wk at gnupg.org>
Date:   Thu Dec 13 09:07:28 2001 +0000

    Fixed INPUT/OUTPUT command
---
 src/assuan-handler.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/assuan-handler.c b/src/assuan-handler.c
index c8be909..ff8024a 100644
--- a/src/assuan-handler.c
+++ b/src/assuan-handler.c
@@ -88,8 +88,9 @@ parse_cmd_input_output (ASSUAN_CONTEXT ctx, char *line, int *rfd)
   if (!digitp (*line))
     return set_error (ctx, Syntax_Error, "number required");
   *rfd = strtoul (line, &endp, 10);
-  if (*endp)
-    return set_error (ctx, Syntax_Error, "garbage found");
+  /* remove that argument so that a notify handler won't see it */
+  memset (line, ' ', endp? (endp-line):strlen(line));
+
   if (*rfd == ctx->inbound.fd)
     return set_error (ctx, Parameter_Conflict, "fd same as inbound fd");
   if (*rfd == ctx->outbound.fd)
@@ -381,7 +382,7 @@ process_request (ASSUAN_CONTEXT ctx)
     }
   else if (rc == -1)
     { /* No error checking because the peer may have already disconnect */ 
-      assuan_write_line (ctx, "OK  Hope to meet you again");
+      assuan_write_line (ctx, "OK closing connection");
     }
   else 
     {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/libassuan.git



More information about the Pkg-gnupg-commit mailing list