smbd: Use share_mode_entry's lease data in is_same_lease()
authorVolker Lendecke <vl@samba.org>
Wed, 19 Sep 2018 12:29:23 +0000 (14:29 +0200)
committerChristof Schmitt <cs@samba.org>
Sun, 14 Apr 2019 04:01:31 +0000 (04:01 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
source3/smbd/open.c

index 6d22550abfb39e6f61ced5407627e821aa40a3a8..07f7c7ec194f12fd4ae78ec73bb52e44b2c74b6c 100644 (file)
@@ -2193,8 +2193,8 @@ static bool is_same_lease(const files_struct *fsp,
 
        return smb2_lease_equal(fsp_client_guid(fsp),
                                &lease->lease_key,
-                               &d->leases[e->lease_idx].client_guid,
-                               &d->leases[e->lease_idx].lease_key);
+                               &e->client_guid,
+                               &e->lease_key);
 }
 
 static int map_lease_type_to_oplock(uint32_t lease_type)