diff options
author | Tobias Stoeckmann <tobias@cvs.openbsd.org> | 2008-01-21 16:36:47 +0000 |
---|---|---|
committer | Tobias Stoeckmann <tobias@cvs.openbsd.org> | 2008-01-21 16:36:47 +0000 |
commit | 15898420b698ef6903c46af4084c532aeb09cc81 (patch) | |
tree | 1cb38fa4340dee984513f42b3b6233b86260c637 /usr.bin/cvs/util.c | |
parent | 0e676bb7aa999a2d725c7a7655fe84ee5e6e77f2 (diff) |
Fixed export to be fully functional and compliant to GNU cvs in local and
remote setups.
OK xsa@
Diffstat (limited to 'usr.bin/cvs/util.c')
-rw-r--r-- | usr.bin/cvs/util.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/usr.bin/cvs/util.c b/usr.bin/cvs/util.c index fbf95c8b91e..e5d76a25b2f 100644 --- a/usr.bin/cvs/util.c +++ b/usr.bin/cvs/util.c @@ -1,4 +1,4 @@ -/* $OpenBSD: util.c,v 1.124 2008/01/10 10:09:27 tobias Exp $ */ +/* $OpenBSD: util.c,v 1.125 2008/01/21 16:36:46 tobias Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org> * Copyright (c) 2005, 2006 Joris Vink <joris@openbsd.org> @@ -505,7 +505,8 @@ cvs_get_repository_name(const char *dir, char *dst, size_t len) } } } else { - if (cvs_cmdop != CVS_OP_CHECKOUT) { + if ((cvs_cmdop == CVS_OP_EXPORT && strcmp(dir, ".")) || + cvs_cmdop != CVS_OP_CHECKOUT) { if (strlcat(dst, dir, len) >= len) fatal("cvs_get_repository_name: " "truncation"); @@ -616,6 +617,9 @@ cvs_mkpath(const char *path, char *tag) if (mkdir(rpath, 0755) == -1 && errno != EEXIST) fatal("cvs_mkpath: %s: %s", rpath, strerror(errno)); + if (cvs_cmdop == CVS_OP_EXPORT && !cvs_server_active) + continue; + cvs_mkadmin(rpath, current_cvsroot->cr_str, repo, tag, NULL, 0); |