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

UnionFile.Readdir return io.EOF on empty dir when c=-1 #197

Closed
moorereason opened this issue Feb 22, 2019 · 0 comments
Closed

UnionFile.Readdir return io.EOF on empty dir when c=-1 #197

moorereason opened this issue Feb 22, 2019 · 0 comments
Labels

Comments

@moorereason
Copy link
Contributor

A bug was recently introduced in b158c09. UnionFile.Readdir doesn't properly handle the empty directory case where f.off == len(f.files) == 0 && c == -1. Readdir should only return io.EOF if c > 0.

@bep bep added the bug label Feb 22, 2019
moorereason added a commit to moorereason/afero that referenced this issue Mar 2, 2019
Update Readdir to match behavior of stdlib os package.

Fixes spf13#197
@bep bep closed this as completed in #199 Mar 26, 2019
bep pushed a commit that referenced this issue Mar 26, 2019
Update Readdir to match behavior of stdlib os package.

Fixes #197
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants