summaryrefslogtreecommitdiffstats
path: root/usr.bin/cvs
diff options
context:
space:
mode:
authorjfb <jfb@openbsd.org>2005-02-25 20:30:36 +0000
committerjfb <jfb@openbsd.org>2005-02-25 20:30:36 +0000
commit951a953e5542ec6f455816a0ffa96724df8c9ab0 (patch)
tree4a1fb323fb325956a482ea28436f0bb2eef3b05a /usr.bin/cvs
parentadd rcsnum_parse() to simplify the most common case (diff)
downloadwireguard-openbsd-951a953e5542ec6f455816a0ffa96724df8c9ab0.tar.xz
wireguard-openbsd-951a953e5542ec6f455816a0ffa96724df8c9ab0.zip
exit with an error message if cvs_file_init() fails
Diffstat (limited to 'usr.bin/cvs')
-rw-r--r--usr.bin/cvs/cvs.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.bin/cvs/cvs.c b/usr.bin/cvs/cvs.c
index 13b7b594906..de42c0c2482 100644
--- a/usr.bin/cvs/cvs.c
+++ b/usr.bin/cvs/cvs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cvs.c,v 1.39 2005/02/03 23:00:42 xsa Exp $ */
+/* $OpenBSD: cvs.c,v 1.40 2005/02/25 20:30:36 jfb Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -387,7 +387,10 @@ main(int argc, char **argv)
/* setup signal handlers */
signal(SIGPIPE, SIG_IGN);
- cvs_file_init();
+ if (cvs_file_init() < 0) {
+ cvs_log(LP_ERR, "failed to initialize file support");
+ exit(1);
+ }
ret = -1;