diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2012-09-07 06:02:53 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2012-09-07 06:02:53 -0400 |
commit | 2240d9ca9f1b367ef985eef8a3a028936ac71f56 (patch) | |
tree | 3c9543b96e5eb24b35836942db7c508fc239a8da /gpsdecode.c | |
parent | c6e26279e448cb50d26aa308a1473a1d192b192a (diff) | |
download | gpsd-2240d9ca9f1b367ef985eef8a3a028936ac71f56.tar.gz |
Replace exit({0,1}) with exit(EXIT_{SUCCESS,FAILURE})
Note there are some exit(2) instances we bneed to decide what to do with.
Diffstat (limited to 'gpsdecode.c')
-rw-r--r-- | gpsdecode.c | 10 |
1 files changed, 5 insertions, 5 deletions
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 */ |