From 69f85b8f3943f0e8ed87dc7afd8e87868f516966 Mon Sep 17 00:00:00 2001 From: Tristan Riehs Date: Sat, 11 Nov 2023 21:12:47 +0100 Subject: error messages made consistent --- rpt.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/rpt.c b/rpt.c index ce3260c..2abdaf0 100644 --- a/rpt.c +++ b/rpt.c @@ -52,7 +52,7 @@ exit_on_error(int status) if (!status) return; - fprintf(stderr, "Child process exited with status %d, aborting.\n", + fprintf(stderr, "rpt: child process exited with status %d, aborting\n", status); exit(status); } @@ -75,7 +75,7 @@ exec_child(char **argv) if (status < 0) { - perror("rpt[child process]"); + perror("lseek"); exit(4); } } @@ -84,7 +84,7 @@ exec_child(char **argv) if (status < 0) { - perror("rpt[child process]"); + perror("dup2"); exit(4); } @@ -92,7 +92,7 @@ exec_child(char **argv) if (status < 0) { - perror("rpt[child process]"); + perror("execvp"); exit(4); } @@ -116,7 +116,7 @@ invoke_cmd(char **argv, void (*handle_error_f)(int status)) if (pid < 0) { - perror("rpt"); + perror("fork"); exit(4); } @@ -145,7 +145,7 @@ copy_stdin() if (!stdin_clone) { - perror("rpt"); + perror("tmpfile"); exit(1); } @@ -160,7 +160,7 @@ copy_stdin() if (errno) { fclose(stdin_clone); - perror("rpt"); + perror("read/write"); exit(1); } } -- cgit v1.2.3