summaryrefslogtreecommitdiffstats
path: root/usr.sbin/rpc.lockd/lock_proc.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/rpc.lockd/lock_proc.c')
-rw-r--r--usr.sbin/rpc.lockd/lock_proc.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.sbin/rpc.lockd/lock_proc.c b/usr.sbin/rpc.lockd/lock_proc.c
index 076f0ee7..c526be1 100644
--- a/usr.sbin/rpc.lockd/lock_proc.c
+++ b/usr.sbin/rpc.lockd/lock_proc.c
@@ -295,7 +295,7 @@ get_client(host_addr, vers)
host_addr->sa_len);
clnt_cache_vers[clnt_cache_next_to_use] = vers;
clnt_cache_time[clnt_cache_next_to_use] = time_now.tv_sec;
- if (++clnt_cache_next_to_use > CLIENT_CACHE_SIZE)
+ if (++clnt_cache_next_to_use >= CLIENT_CACHE_SIZE)
clnt_cache_next_to_use = 0;
/*
@@ -386,7 +386,10 @@ nlmtonlm4(arg, arg4)
struct nlm_lock *arg;
struct nlm4_lock *arg4;
{
- memcpy(arg4, arg, sizeof(nlm_lock));
+ arg4->caller_name = arg->caller_name;
+ arg4->fh = arg->fh;
+ arg4->oh = arg->oh;
+ arg4->svid = arg->svid;
arg4->l_offset = arg->l_offset;
arg4->l_len = arg->l_len;
}
OpenPOWER on IntegriCloud