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

fs::remove_all cannot delete non-directory files #6

Closed
actboy168 opened this issue Mar 5, 2019 · 4 comments
Closed

fs::remove_all cannot delete non-directory files #6

actboy168 opened this issue Mar 5, 2019 · 4 comments
Assignees
Labels
available on master Fix is done on master branch, issue closed on next release bug Something isn't working high Severity: high
Milestone

Comments

@actboy168
Copy link
Contributor

Describe the bug
fs::remove_all should allow deletion of a file.

To Reproduce

assert(fs::remove_all("test.txt") == 1)
assert(fs::remove_all("test.txt") == 0)

Expected behavior
But now it will throw an exception.

Additional context

@gulrak gulrak added bug Something isn't working high Severity: high labels Mar 5, 2019
@gulrak gulrak self-assigned this Mar 5, 2019
@gulrak gulrak added this to the v1.0.8 milestone Mar 5, 2019
@gulrak
Copy link
Owner

gulrak commented Mar 5, 2019

Indeed, thanks for reporting! I will push a fix on master when I'm back home and I scheduled a release for next sunday.

@gulrak gulrak added the available on master Fix is done on master branch, issue closed on next release label Mar 5, 2019
@actboy168
Copy link
Contributor Author

Hi, it still has a small problem. When removing a file that does not exist, fs::remove_all should return 0, but it is now 1.

@gulrak
Copy link
Owner

gulrak commented Mar 6, 2019

True, added a test and a fix for that.

@gulrak
Copy link
Owner

gulrak commented Mar 16, 2019

Closed with release of v1.0.8

@gulrak gulrak closed this as completed Mar 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
available on master Fix is done on master branch, issue closed on next release bug Something isn't working high Severity: high
Projects
None yet
Development

No branches or pull requests

2 participants