mirror of
https://github.com/samba-team/samba.git
synced 2025-02-04 17:47:26 +03:00
smbd: Use brl_delete_lock_struct in brl_lock_cancel_default
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
f93ae07679
commit
28df2b0d0d
@ -1509,12 +1509,7 @@ bool brl_lock_cancel_default(struct byte_range_lock *br_lck,
|
||||
return False;
|
||||
}
|
||||
|
||||
if (i < br_lck->num_locks - 1) {
|
||||
/* Found this particular pending lock - delete it */
|
||||
memmove(&locks[i], &locks[i+1],
|
||||
sizeof(*locks)*((br_lck->num_locks-1) - i));
|
||||
}
|
||||
|
||||
brl_delete_lock_struct(locks, br_lck->num_locks, i);
|
||||
br_lck->num_locks -= 1;
|
||||
br_lck->modified = True;
|
||||
return True;
|
||||
|
Loading…
x
Reference in New Issue
Block a user