summaryrefslogtreecommitdiffstats
path: root/usr.sbin/rpc.lockd
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>1997-08-10 21:06:39 +0000
committermillert <millert@openbsd.org>1997-08-10 21:06:39 +0000
commit2950da7fe78bcb84c41136b91e10e0561fbdd1f3 (patch)
treedb7e1a087443798db60fd4b8ef39f5c858a0769e /usr.sbin/rpc.lockd
parentLine up better with -t. (diff)
downloadwireguard-openbsd-2950da7fe78bcb84c41136b91e10e0561fbdd1f3.tar.xz
wireguard-openbsd-2950da7fe78bcb84c41136b91e10e0561fbdd1f3.zip
Pass -Wall and add OpenBSD tags.
Diffstat (limited to 'usr.sbin/rpc.lockd')
-rw-r--r--usr.sbin/rpc.lockd/handles.c2
-rw-r--r--usr.sbin/rpc.lockd/lockd.c7
-rw-r--r--usr.sbin/rpc.lockd/lockd.h5
-rw-r--r--usr.sbin/rpc.lockd/procs.c7
-rw-r--r--usr.sbin/rpc.lockd/rpc.lockd.88
-rw-r--r--usr.sbin/rpc.lockd/test.c2
6 files changed, 23 insertions, 8 deletions
diff --git a/usr.sbin/rpc.lockd/handles.c b/usr.sbin/rpc.lockd/handles.c
index 047f6d23ee3..abe9c0bff0c 100644
--- a/usr.sbin/rpc.lockd/handles.c
+++ b/usr.sbin/rpc.lockd/handles.c
@@ -1,3 +1,5 @@
+/* $OpenBSD: handles.c,v 1.2 1997/08/10 21:06:39 millert Exp $ */
+
/*
* Copyright (c) 1995
* A.R. Gordon (andrew.gordon@net-tel.co.uk). All rights reserved.
diff --git a/usr.sbin/rpc.lockd/lockd.c b/usr.sbin/rpc.lockd/lockd.c
index 1a416f66f8c..7aa1b9d9b87 100644
--- a/usr.sbin/rpc.lockd/lockd.c
+++ b/usr.sbin/rpc.lockd/lockd.c
@@ -1,3 +1,5 @@
+/* $OpenBSD: lockd.c,v 1.3 1997/08/10 21:06:40 millert Exp $ */
+
/*
* Copyright (c) 1995
* A.R. Gordon (andrew.gordon@net-tel.co.uk). All rights reserved.
@@ -47,7 +49,10 @@ int debug_level = 0; /* Zero means no debugging syslog() calls */
int _rpcsvcdirty;
#endif
-main(int argc, char **argv)
+int
+main(argc, argv)
+ int argc;
+ char **argv;
{
SVCXPRT *transp;
diff --git a/usr.sbin/rpc.lockd/lockd.h b/usr.sbin/rpc.lockd/lockd.h
index 39586bfd77a..50f9c57b9a0 100644
--- a/usr.sbin/rpc.lockd/lockd.h
+++ b/usr.sbin/rpc.lockd/lockd.h
@@ -1,3 +1,5 @@
+/* $OpenBSD: lockd.h,v 1.2 1997/08/10 21:06:40 millert Exp $ */
+
/*
* Copyright (c) 1995
* A.R. Gordon (andrew.gordon@net-tel.co.uk). All rights reserved.
@@ -34,7 +36,10 @@
#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
#include <rpc/rpc.h>
+#include <rpc/pmap_clnt.h>
#include <syslog.h>
#include <rpcsvc/sm_inter.h> /* protocol to talk to rpc.statd */
#include "nlm_prot.h" /* The protocol we are implementing */
diff --git a/usr.sbin/rpc.lockd/procs.c b/usr.sbin/rpc.lockd/procs.c
index d023ad5a76e..5114c193aa6 100644
--- a/usr.sbin/rpc.lockd/procs.c
+++ b/usr.sbin/rpc.lockd/procs.c
@@ -1,3 +1,5 @@
+/* $OpenBSD: procs.c,v 1.6 1997/08/10 21:06:40 millert Exp $ */
+
/*
* Copyright (c) 1995
* A.R. Gordon (andrew.gordon@net-tel.co.uk). All rights reserved.
@@ -40,7 +42,6 @@
#include <netinet/in.h>
#include <arpa/inet.h>
#include <netdb.h>
-#include <string.h>
#define CLIENT_CACHE_SIZE 64 /* No. of client sockets cached */
@@ -206,7 +207,7 @@ static void transmit_result(int opcode, nlm_res *result, struct svc_req *req)
struct timeval timeo;
addr = svc_getcaller(req->rq_xprt);
- if (cli = get_client(addr))
+ if ((cli = get_client(addr)))
{
timeo.tv_sec = 0; /* No timeout - not expecting response */
timeo.tv_usec = 0;
@@ -285,7 +286,7 @@ void *nlm_test_msg_1_svc(nlm_testargs *arg, struct svc_req *rqstp)
/* nlm_test has different result type to the other operations, so */
/* can't use transmit_result() in this case */
addr = svc_getcaller(rqstp->rq_xprt);
- if (cli = get_client(addr))
+ if ((cli = get_client(addr)))
{
timeo.tv_sec = 0; /* No timeout - not expecting response */
timeo.tv_usec = 0;
diff --git a/usr.sbin/rpc.lockd/rpc.lockd.8 b/usr.sbin/rpc.lockd/rpc.lockd.8
index 4a878e33933..07a952e861c 100644
--- a/usr.sbin/rpc.lockd/rpc.lockd.8
+++ b/usr.sbin/rpc.lockd/rpc.lockd.8
@@ -1,4 +1,4 @@
-.\" -*- nroff -*-
+.\" $OpenBSD: rpc.lockd.8,v 1.5 1997/08/10 21:06:41 millert Exp $
.\"
.\" Copyright (c) 1995 A.R.Gordon, andrew.gordon@net-tel.co.uk
.\" All rights reserved.
@@ -60,7 +60,7 @@ debug levels can be specified, causing display of operation arguments
and internal operations of the daemon.
.El
.Pp
-Error conditions are logged to syslog, irrespecive of the debug level,
+Error conditions are logged to syslog, irrespective of the debug level,
using log level LOG_ERR and facility LOG_DAEMON.
.Pp
The
@@ -77,9 +77,9 @@ after the network has been started.
RPC protocol specification for the network lock manager protocol.
.El
.Sh SEE ALSO
-.Xr rpc.statd 8 ,
+.Xr syslog 3 ,
.Xr rc 8 ,
-.Xr syslog 3
+.Xr rpc.statd 8
.Sh BUGS
The current implementation provides only the server side of the protocol
(ie. clients running other OS types can establish locks on a OpenBSD fileserver,
diff --git a/usr.sbin/rpc.lockd/test.c b/usr.sbin/rpc.lockd/test.c
index 2f1eb5ad29f..9d484f5e020 100644
--- a/usr.sbin/rpc.lockd/test.c
+++ b/usr.sbin/rpc.lockd/test.c
@@ -1,3 +1,5 @@
+/* $OpenBSD: test.c,v 1.2 1997/08/10 21:06:41 millert Exp $ */
+
#include <rpc/rpc.h>
#include <rpcsvc/nlm_prot.h>
#ifndef lint