]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
vlserver: Use correct base value when replacing
authorSimon Wilkinson <sxw@your-file-system.com>
Thu, 19 May 2011 17:19:29 +0000 (18:19 +0100)
committerStephan Wiesand <stephan.wiesand@desy.de>
Thu, 29 Aug 2013 10:26:36 +0000 (03:26 -0700)
When we're removing existing address entries the code calculates
a base and index value for each entry that we're removing an address
from. However, it then _uses_ a previously calculated base value,
with the new index. This works fine if the old base and the new base
match, but if they don't, chaos will ensue.

Fix to always use matched base and index pairs.

Reviewed-on: http://gerrit.openafs.org/4771
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
(cherry picked from commit a180b0c5d8991a14f1fbd78d81dcb4754a24f4d3)

Change-Id: I37372f020ad644f30b6dbdd1ed68b56eb1c0f2e2
Reviewed-on: http://gerrit.openafs.org/9429
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Andrew Deason <adeason@sinenomine.net>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
src/vlserver/vlprocs.c

index bfc48bc6fa79e4606f12bc980b483c12d1cf3c3d..22d0687db8975e7f9b10a6b0b64a9df6413f2087 100644 (file)
@@ -2355,7 +2355,7 @@ SVL_RegisterAddrs(struct rx_call *rxcall, afsUUID *uuidp, afs_int32 spare1,
 
        base = (ctx.hostaddress[WillChange[i]] >> 16) & 0xff;
        index = ctx.hostaddress[WillChange[i]] & 0x0000ffff;
-       tex = &ctx.ex_addr[fbase][index];
+       tex = &ctx.ex_addr[base][index];
 
        if (++m == 1)
            VLog(0,