statd - check for 'priv' when looking for duplicate registrations.
authorNeil Brown <neilb@suse.de>
Thu, 29 Mar 2007 03:08:07 +0000 (13:08 +1000)
committerNeil Brown <neilb@suse.de>
Thu, 29 Mar 2007 03:08:07 +0000 (13:08 +1000)
From the point of view of the client (lockd), the 'priv' blob is probably
the most important key, so make sure to not throw away requests with
new 'priv' information.

Signed-off-by: Neil Brown <neilb@suse.de>
utils/statd/monitor.c

index 5fcab1d..b0b19da 100644 (file)
@@ -145,7 +145,8 @@ sm_mon_1_svc(struct mon *argp, struct svc_req *rqstp)
                if (matchhostname(NL_MY_NAME(clnt), my_name) &&
                    NL_MY_PROC(clnt) == id->my_proc &&
                    NL_MY_PROG(clnt) == id->my_prog &&
-                   NL_MY_VERS(clnt) == id->my_vers) {
+                   NL_MY_VERS(clnt) == id->my_vers &&
+                   memcmp(NL_PRIV(clnt), argp->priv, SM_PRIV_SIZE) == 0) {
                        /* Hey!  We already know you guys! */
                        dprintf(N_DEBUG,
                                "Duplicate SM_MON request for %s "