Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: don't remove lock on dir when deleting a child node #1335

Merged
merged 1 commit into from
Nov 17, 2021
Merged

Fix: don't remove lock on dir when deleting a child node #1335

merged 1 commit into from
Nov 17, 2021

Conversation

tbsmark86
Copy link

Current behavior:

  1. lock /somedir/
  2. delete /somedir/somefile.txt (with token)
  3. put /somedir/newfile.txt (with token)
    => ERROR precondition failed

Expected/Fixed behavior:
Step 3) should be executed under the LOCK.

@tbsmark86 tbsmark86 closed this Mar 12, 2021
@tbsmark86 tbsmark86 reopened this Mar 12, 2021
@tbsmark86 tbsmark86 closed this Mar 12, 2021
@tbsmark86 tbsmark86 reopened this Mar 12, 2021
@codecov
Copy link

codecov bot commented Mar 12, 2021

Codecov Report

Merging #1335 (76d6592) into master (ba97a9f) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #1335   +/-   ##
=========================================
  Coverage     97.35%   97.35%           
- Complexity     2809     2810    +1     
=========================================
  Files           174      174           
  Lines          7976     7978    +2     
=========================================
+ Hits           7765     7767    +2     
  Misses          211      211           
Impacted Files Coverage Δ
lib/DAV/Locks/Plugin.php 98.34% <100.00%> (+0.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ba97a9f...76d6592. Read the comment docs.

@phil-davis
Copy link
Contributor

Assigned myself so that I find this easily to followup.

Copy link
Contributor

@phil-davis phil-davis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
Note: ownCloud is using its own implementation of locking and so I could not reproduce this on ownCloud - I don't think it ever executes this code.

@phil-davis phil-davis merged commit 75e3e88 into sabre-io:master Nov 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants