summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjfb <jfb@openbsd.org>2004-08-02 17:34:10 +0000
committerjfb <jfb@openbsd.org>2004-08-02 17:34:10 +0000
commit03c5056e3468deecc394eef8264df6197e585553 (patch)
treeb2ece025dda2c98103d6acb64f0f57ffd33fc380
parent* no locks for now (diff)
downloadwireguard-openbsd-03c5056e3468deecc394eef8264df6197e585553.tar.xz
wireguard-openbsd-03c5056e3468deecc394eef8264df6197e585553.zip
* wrap more code between program-dependent ifdef's and fix a bug while
we're at it
-rw-r--r--usr.bin/cvs/sock.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/usr.bin/cvs/sock.c b/usr.bin/cvs/sock.c
index 923faf27c24..7415f18e925 100644
--- a/usr.bin/cvs/sock.c
+++ b/usr.bin/cvs/sock.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sock.c,v 1.3 2004/08/02 17:30:10 jfb Exp $ */
+/* $OpenBSD: sock.c,v 1.4 2004/08/02 17:34:10 jfb Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -49,12 +49,16 @@ char *cvsd_sock_path = CVSD_SOCK_PATH;
/* daemon API */
+#ifdef CVSD
int cvsd_sock = -1;
static struct sockaddr_un cvsd_sun;
+#endif
/* for client API */
+#ifdef CVS
static int cvs_sock = -1;
static struct sockaddr_un cvs_sun;
+#endif
#ifdef CVSD
@@ -69,7 +73,7 @@ static struct sockaddr_un cvs_sun;
int
cvsd_sock_open(void)
{
- if (cvs_sock >= 0)
+ if (cvsd_sock >= 0)
cvsd_sock_close();
cvsd_sun.sun_family = AF_LOCAL;