Linux: Fix conversion of whole-file locks
authorAnders Kaseorg <andersk@mit.edu>
Sun, 21 Feb 2010 01:28:42 +0000 (20:28 -0500)
committerDerrick Brashear <shadow@dementia.org>
Tue, 23 Feb 2010 19:42:00 +0000 (11:42 -0800)
commitd3abbebcb0651c5d2c7a3094270fd4f86bea3c1e
tree8c988b87a40e9f10ef64e8506de5a4c3f0c3190e
parent2cd1335257f069d534603c755fa18c4ee2cb4b5e
Linux: Fix conversion of whole-file locks

An overflow bug in commit 49b7bbdd3b45df694fadbef48f9ed99d9bfe07b9
caused whole-file locks to be treated as byte-range locks, which fail
to be propagated to other machines.

Fix this by setting l_len = 0 for locks that range to the end of the
file.

FIXES 126561

Change-Id: Ie2dc9d04f33559c73b3b86b64152c549b785f8ad
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Reviewed-on: http://gerrit.openafs.org/1352
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
src/afs/LINUX/osi_vnodeops.c
src/afs/LINUX24/osi_vnodeops.c