summaryrefslogtreecommitdiff
path: root/usr.bin/cvs
diff options
context:
space:
mode:
authorTobias Stoeckmann <tobias@cvs.openbsd.org>2008-02-10 13:01:09 +0000
committerTobias Stoeckmann <tobias@cvs.openbsd.org>2008-02-10 13:01:09 +0000
commitb249eb59e8a0195ea9125dc8b79d360fd6a448c7 (patch)
tree6dc36d9d578a6c9906b62cff6b129187fc80cd42 /usr.bin/cvs
parentcb79fff8af6a29efb88836b4c22e969a59d4a442 (diff)
Respond with "Updated" instead of "Checked-in" on server-side if a client
committed files, so keywords are expanded properly. On client-side, we have to be careful about Directory ./ when it comes to commits, so add a test for CVS_OP_COMMIT. OK and help from joris@
Diffstat (limited to 'usr.bin/cvs')
-rw-r--r--usr.bin/cvs/checkout.c6
-rw-r--r--usr.bin/cvs/util.c4
2 files changed, 5 insertions, 5 deletions
diff --git a/usr.bin/cvs/checkout.c b/usr.bin/cvs/checkout.c
index 241db2abf03..b9a2ea34d43 100644
--- a/usr.bin/cvs/checkout.c
+++ b/usr.bin/cvs/checkout.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: checkout.c,v 1.136 2008/02/10 10:21:42 joris Exp $ */
+/* $OpenBSD: checkout.c,v 1.137 2008/02/10 13:01:08 tobias Exp $ */
/*
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
*
@@ -538,7 +538,7 @@ cvs_checkout_file(struct cvs_file *cf, RCSNUM *rnum, char *tag, int co_flags)
}
if (co_flags & CO_COMMIT)
- cvs_server_update_entry("Checked-in", cf);
+ cvs_server_update_entry("Updated", cf);
else if (co_flags & CO_MERGE)
cvs_server_update_entry("Merged", cf);
else if (co_flags & CO_REMOVE)
@@ -551,7 +551,7 @@ cvs_checkout_file(struct cvs_file *cf, RCSNUM *rnum, char *tag, int co_flags)
xfree(entry);
}
- if (!(co_flags & CO_COMMIT) && !(co_flags & CO_REMOVE)) {
+ if (!(co_flags & CO_REMOVE)) {
if (!(co_flags & CO_MERGE)) {
(void)xsnprintf(template, MAXPATHLEN,
"%s/checkout.XXXXXXXXXX", cvs_tmpdir);
diff --git a/usr.bin/cvs/util.c b/usr.bin/cvs/util.c
index 9db61d7b254..b9769669e6e 100644
--- a/usr.bin/cvs/util.c
+++ b/usr.bin/cvs/util.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: util.c,v 1.136 2008/02/10 11:52:35 joris Exp $ */
+/* $OpenBSD: util.c,v 1.137 2008/02/10 13:01:08 tobias Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* Copyright (c) 2005, 2006 Joris Vink <joris@openbsd.org>
@@ -567,7 +567,7 @@ cvs_mkpath(const char *path, char *tag)
repo[0] = '\0';
rpath[0] = '\0';
- if (cvs_cmdop == CVS_OP_UPDATE) {
+ if (cvs_cmdop == CVS_OP_UPDATE || cvs_cmdop == CVS_OP_COMMIT) {
if ((fp = fopen(CVS_PATH_REPOSITORY, "r")) != NULL) {
if ((fgets(repo, sizeof(repo), fp)) == NULL)
fatal("cvs_mkpath: bad repository file");