summary refs log tree commit diff
path: root/bin/dehtml.l
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2024-05-22 12:16:41 -0400
committerJune McEnroe <june@causal.agency>2024-05-22 12:16:41 -0400
commit625662a5c1cbb71cf37653df1f31cd60c48b18ae (patch)
tree7a04a48f7007b30f086b353c0c03002c861383b9 /bin/dehtml.l
parentAdd photo descriptions from 05-03 and 05-06 (diff)
downloadsrc-625662a5c1cbb71cf37653df1f31cd60c48b18ae.tar.gz
src-625662a5c1cbb71cf37653df1f31cd60c48b18ae.zip
Remove use of sysexits.h
Diffstat (limited to '')
-rw-r--r--bin/dehtml.l5
1 files changed, 2 insertions, 3 deletions
diff --git a/bin/dehtml.l b/bin/dehtml.l
index 799f0926..b6aa4eb8 100644
--- a/bin/dehtml.l
+++ b/bin/dehtml.l
@@ -47,7 +47,6 @@ enum Token {
 #include <stdlib.h>
 #include <string.h>
 #include <strings.h>
-#include <sysexits.h>
 #include <unistd.h>
 #include <wchar.h>
 
@@ -107,7 +106,7 @@ int main(int argc, char *argv[]) {
 	for (int opt; 0 < (opt = getopt(argc, argv, "s"));) {
 		switch (opt) {
 			break; case 's': collapse = true;
-			break; default:  return EX_USAGE;
+			break; default:  return 1;
 		}
 	}
 	argc -= optind;
@@ -116,7 +115,7 @@ int main(int argc, char *argv[]) {
 	if (!argc) argc++;
 	for (int i = 0; i < argc; ++i) {
 		yyin = (argv[i] ? fopen(argv[i], "r") : stdin);
-		if (!yyin) err(EX_NOINPUT, "%s", argv[i]);
+		if (!yyin) err(1, "%s", argv[i]);
 
 		bool space = true;
 		bool discard = false;