From 2240d9ca9f1b367ef985eef8a3a028936ac71f56 Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Fri, 7 Sep 2012 06:02:53 -0400 Subject: Replace exit({0,1}) with exit(EXIT_{SUCCESS,FAILURE}) Note there are some exit(2) instances we bneed to decide what to do with. --- gpsdecode.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'gpsdecode.c') diff --git a/gpsdecode.c b/gpsdecode.c index f08cc98b..26649f97 100644 --- a/gpsdecode.c +++ b/gpsdecode.c @@ -604,7 +604,7 @@ static void encode(FILE *fpin, FILE *fpout) (void)fprintf(stderr, "gpsdecode: dying with status %d (%s) on line %d\n", status, json_error_string(status), lineno); - exit(1); + exit(EXIT_FAILURE); } json_data_report(session.gpsdata.set, &session, &policy, @@ -668,12 +668,12 @@ int main(int argc, char **argv) case 'V': (void)fprintf(stderr, "gpsdecode revision " VERSION "\n"); - exit(0); + exit(EXIT_SUCCESS); case '?': default: (void)fputs("gpsdecode [-v]\n", stderr); - exit(1); + exit(EXIT_FAILURE); } } //argc -= optind; @@ -684,11 +684,11 @@ int main(int argc, char **argv) encode(stdin, stdout); #else (void)fprintf(stderr, "gpsdecode: encoding support isn't compiled.\n"); - exit(1); + exit(EXIT_FAILURE); #endif /* SOCKET_EXPORT_ENABLE */ } else decode(stdin, stdout); - exit(0); + exit(EXIT_SUCCESS); } /* gpsdecode.c ends here */ -- cgit v1.2.1