diff options
author | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-06-12 13:56:01 +0000 |
---|---|---|
committer | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-06-12 13:56:01 +0000 |
commit | 6bd48e46af8eb5cb552c4a1a5e1b55f92d293313 (patch) | |
tree | 290a739ba1ffe860bab172e4b3b108e916198c65 /usr.bin/cvs/cvs.c | |
parent | 9eae8747e87cf89235d397a72470b28d8bfad58e (diff) |
bring back a working version of the `cvs init' command. OK joris@.
Diffstat (limited to 'usr.bin/cvs/cvs.c')
-rw-r--r-- | usr.bin/cvs/cvs.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/cvs/cvs.c b/usr.bin/cvs/cvs.c index b4092587780..920a5148b78 100644 --- a/usr.bin/cvs/cvs.c +++ b/usr.bin/cvs/cvs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cvs.c,v 1.102 2006/06/02 19:10:23 david Exp $ */ +/* $OpenBSD: cvs.c,v 1.103 2006/06/12 13:56:00 xsa Exp $ */ /* * Copyright (c) 2006 Joris Vink <joris@openbsd.org> * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org> @@ -228,7 +228,7 @@ main(int argc, char **argv) i = snprintf(fpath, sizeof(fpath), "%s/%s", current_cvsroot->cr_dir, CVS_PATH_ROOT); - if (stat(fpath, &st) == -1) { + if (stat(fpath, &st) == -1 && cvs_cmdop != CVS_OP_INIT) { if (errno == ENOENT) fatal("'%s' does not seem to be a valid repository", current_cvsroot->cr_dir); @@ -241,7 +241,8 @@ main(int argc, char **argv) current_cvsroot->cr_dir); } - cvs_parse_configfile(); + if (cvs_cmdop != CVS_OP_INIT) + cvs_parse_configfile(); umask(cvs_umask); |