diff options
Diffstat (limited to 'git_hooks_client')
-rw-r--r-- | git_hooks_client/git_hooks_client.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/git_hooks_client/git_hooks_client.c b/git_hooks_client/git_hooks_client.c index b5e4ed8..e00ab3a 100644 --- a/git_hooks_client/git_hooks_client.c +++ b/git_hooks_client/git_hooks_client.c @@ -8,8 +8,14 @@ #include <sys/stat.h> #include <string.h> #include <fcntl.h> +#include <signal.h> int main(int argc, char *argv[]) { + if (signal(SIGPIPE, SIG_IGN) == SIG_ERR) { + perror("signal"); + return EXIT_FAILURE; + } + const char *socket_path = getenv("LINDENII_FORGE_HOOKS_SOCKET_PATH"); if (socket_path == NULL) { dprintf(STDERR_FILENO, "environment variable LINDENII_FORGE_HOOKS_SOCKET_PATH undefined\n"); |