From 04ea03781f26812d3eb39c4d5d819b332722a96e Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Thu, 11 Oct 2012 12:23:58 -0400 Subject: [PATCH] gpgme-tools: add spaces between function names and arguments. Signed-off-by: W. Trevor King --- src/gpgme-tool.c | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/src/gpgme-tool.c b/src/gpgme-tool.c index 556471a..bcda5f0 100644 --- a/src/gpgme-tool.c +++ b/src/gpgme-tool.c @@ -636,16 +636,16 @@ cleanup_handler (int signum) { if (socket_fd >= 0) { - close(socket_fd); + close (socket_fd); /* unix only */ socket_fd = -1; } if (socket_path) { - unlink(socket_path); - free(socket_path); + unlink (socket_path); + free (socket_path); socket_path = NULL; } - exit(EXIT_SUCCESS); + exit (EXIT_SUCCESS); } void log_error (int status, gpg_error_t errnum, @@ -3443,19 +3443,19 @@ expand_path(char *raw_path) { /* TODO: check for WRDE_BADCHAR, etc. */ fprintf (log_stream, "could not expand socket path\n"); - exit(EXIT_FAILURE); + exit (EXIT_FAILURE); } if (words.we_wordc != 1) { fprintf (log_stream, "expanded socket path into %d fields\n", words.we_wordc); - exit(EXIT_FAILURE); + exit (EXIT_FAILURE); } path = malloc (sizeof(char) * (strlen(words.we_wordv[0]) + 1)); if (! path) { - perror("can't allocate path"); - exit(EXIT_FAILURE); + perror ("can't allocate path"); + exit (EXIT_FAILURE); } strcpy (path, words.we_wordv[0]); @@ -3499,31 +3499,31 @@ gpgme_server (gpgme_tool_t gt, int socket_server) { struct sockaddr_un addr; - socket_fd = socket(AF_UNIX, SOCK_STREAM, 0); + socket_fd = socket (AF_UNIX, SOCK_STREAM, 0); if (socket_fd == -1) { - perror("can't create stream socket"); - exit(EXIT_FAILURE); + perror ("can't create stream socket"); + exit (EXIT_FAILURE); } addr.sun_family = AF_UNIX; - socket_path = expand_path("~/.gnupg/S.gpgme-tool"); + socket_path = expand_path ("~/.gnupg/S.gpgme-tool"); strcpy (addr.sun_path, socket_path); if (bind (socket_fd, (struct sockaddr *) &addr, sizeof(struct sockaddr_un))) { - perror("can't bind to stream socket"); - exit(EXIT_FAILURE); + perror ("can't bind to stream socket"); + exit (EXIT_FAILURE); } - signal(SIGINT, &cleanup_handler); - signal(SIGTERM, &cleanup_handler); + signal (SIGINT, &cleanup_handler); + signal (SIGTERM, &cleanup_handler); - listen(socket_fd, 5); + listen (socket_fd, 5); for (;;) { - sock = accept(socket_fd, NULL, 0); + sock = accept (socket_fd, NULL, 0); if (sock == -1) { perror("accept"); @@ -3531,8 +3531,8 @@ gpgme_server (gpgme_tool_t gt, int socket_server) } if ((pid = fork ()) == -1) { - perror("fork"); - close(sock); + perror ("fork"); + close (sock); sock = -1; continue; } @@ -3544,8 +3544,8 @@ gpgme_server (gpgme_tool_t gt, int socket_server) } /* the child doesn't need cleanup handlers */ - signal(SIGINT, SIG_DFL); - signal(SIGTERM, SIG_DFL); + signal (SIGINT, SIG_DFL); + signal (SIGTERM, SIG_DFL); err = assuan_init_socket_server ( server.assuan_ctx, sock, -- 2.26.2