From d537a95fdbc0b4a5f38edea8593b4c085fdd7fcb Mon Sep 17 00:00:00 2001 From: Matt Kraai Date: Fri, 14 Jul 2000 01:51:25 +0000 Subject: Use errorMsg rather than fprintf. --- coreutils/cut.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'coreutils/cut.c') diff --git a/coreutils/cut.c b/coreutils/cut.c index 820074e60..783d526a5 100644 --- a/coreutils/cut.c +++ b/coreutils/cut.c @@ -84,13 +84,13 @@ void cut(void); void warn(int warn_number, char *option) { static char *warn_msg[] = { - "%s: Option -%s allowed only with -f\n", - "%s: -%s overrides earlier option\n", - "%s: -%s not allowed in current mode\n", - "%s: Cannot open %s\n" + "Option -%s allowed only with -f\n", + "-%s overrides earlier option\n", + "-%s not allowed in current mode\n", + "Cannot open %s\n" }; - fprintf(stderr, warn_msg[warn_number], applet_name, option); + errorMsg(warn_msg[warn_number], option); exit_status = warn_number + 1; } @@ -98,15 +98,15 @@ void warn(int warn_number, char *option) void cuterror(int err) { static char *err_mes[] = { - "%s: syntax error\n", - "%s: position must be >0\n", - "%s: line longer than BUFSIZ\n", - "%s: range must not decrease from left to right\n", - "%s: MAX_FIELD exceeded\n", - "%s: MAX_ARGS exceeded\n" + "syntax error\n", + "position must be >0\n", + "line longer than BUFSIZ\n", + "range must not decrease from left to right\n", + "MAX_FIELD exceeded\n", + "MAX_ARGS exceeded\n" }; - fprintf(stderr, err_mes[err - 101], applet_name); + errorMsg(err_mes[err - 101]); exit(err); } -- cgit v1.2.3