summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjfb <jfb@openbsd.org>2004-07-29 18:34:23 +0000
committerjfb <jfb@openbsd.org>2004-07-29 18:34:23 +0000
commit868e9e41a9f6fc388cb6374f9af5200610e02db2 (patch)
treed306ecd54c246fbc9abe0dce5f561e1b17507dc2
parentDon't export `cvs_root' (diff)
downloadwireguard-openbsd-868e9e41a9f6fc388cb6374f9af5200610e02db2.tar.xz
wireguard-openbsd-868e9e41a9f6fc388cb6374f9af5200610e02db2.zip
No more cvs_root
-rw-r--r--usr.bin/cvs/history.c11
-rw-r--r--usr.bin/cvs/proto.c4
2 files changed, 6 insertions, 9 deletions
diff --git a/usr.bin/cvs/history.c b/usr.bin/cvs/history.c
index 3d903484ca8..24cf4379342 100644
--- a/usr.bin/cvs/history.c
+++ b/usr.bin/cvs/history.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: history.c,v 1.1.1.1 2004/07/13 22:02:40 jfb Exp $ */
+/* $OpenBSD: history.c,v 1.2 2004/07/29 18:34:23 jfb Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -58,8 +58,6 @@ static void cvs_history_print (struct cvs_hent *);
extern char *__progname;
-extern struct cvsroot *cvs_root;
-
/*
* cvs_history()
@@ -67,7 +65,6 @@ extern struct cvsroot *cvs_root;
* Handle the `cvs history' command.
*/
-
int
cvs_history(int argc, char **argv)
{
@@ -75,6 +72,7 @@ cvs_history(int argc, char **argv)
u_int nbmod, rep;
char *user, *zone, *tag, *cp;
char *modules[CVS_HISTORY_MAXMOD], histpath[MAXPATHLEN];
+ struct cvsroot *root;
struct cvs_hent *hent;
CVSHIST *hp;
@@ -148,8 +146,9 @@ cvs_history(int argc, char **argv)
else if (rep == 0)
flags |= CVS_HF_O; /* use -o as default */
- if (cvs_root->cr_method == CVS_METHOD_LOCAL) {
- snprintf(histpath, sizeof(histpath), "%s/%s", cvs_root->cr_dir,
+ root = cvsroot_get(".");
+ if (root->cr_method == CVS_METHOD_LOCAL) {
+ snprintf(histpath, sizeof(histpath), "%s/%s", root->cr_dir,
CVS_PATH_HISTORY);
hp = cvs_hist_open(histpath);
if (hp == NULL) {
diff --git a/usr.bin/cvs/proto.c b/usr.bin/cvs/proto.c
index b8eebb5f6db..e701d7eb11d 100644
--- a/usr.bin/cvs/proto.c
+++ b/usr.bin/cvs/proto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: proto.c,v 1.9 2004/07/28 01:49:14 jfb Exp $ */
+/* $OpenBSD: proto.c,v 1.10 2004/07/29 18:34:55 jfb Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -71,8 +71,6 @@ extern int cvs_trace;
extern int cvs_nolog;
extern int cvs_readonly;
-extern struct cvsroot *cvs_root;
-
static int cvs_resp_validreq (int, char *);