mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
* assuan-buffer.c (_assuan_read_line): Add output logging.
(assuan_write_line): Ditto. (_assuan_cookie_write_data): Ditto. (_assuan_cookie_write_flush): Ditto. * assuan-util.c (_assuan_log_print_buffer): New. (assuan_set_log_stream): New. (assuan_begin_confidential): New. (assuan_end_confidential): New. * assuan-defs.h: Add a few handler variables. * assuan-pipe-server.c (assuan_deinit_pipe_server): Removed. (deinit_pipe_server): New. (assuan_deinit_server): New. Changed all callers to use this. * assuan-listen.c (assuan_accept): Use the accept handler. * assuan-handler.c (process_request): Use the close Handler. * assuan-socket-server.c: New.
This commit is contained in:
parent
6af684c118
commit
f58da1883a
11 changed files with 311 additions and 19 deletions
|
@ -387,12 +387,13 @@ process_request (ASSUAN_CONTEXT ctx)
|
|||
else if (rc == -1)
|
||||
{ /* No error checking because the peer may have already disconnect */
|
||||
assuan_write_line (ctx, "OK closing connection");
|
||||
ctx->finish_handler (ctx);
|
||||
}
|
||||
else
|
||||
{
|
||||
char errline[256];
|
||||
|
||||
if (rc < 100)
|
||||
if (rc < 100)
|
||||
sprintf (errline, "ERR %d server fault (%.50s)",
|
||||
ASSUAN_Server_Fault, assuan_strerror (rc));
|
||||
else
|
||||
|
@ -405,6 +406,7 @@ process_request (ASSUAN_CONTEXT ctx)
|
|||
rc = assuan_write_line (ctx, errline);
|
||||
}
|
||||
|
||||
ctx->confidential = 0;
|
||||
if (ctx->okay_line)
|
||||
{
|
||||
xfree (ctx->okay_line);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue