Skip to content

fileops: correct error return on p_lstat failures when mkdir#5302

Merged
ethomson merged 1 commit into
libgit2:masterfrom
tiennou:fix/p_lstat-errno
Nov 16, 2019
Merged

fileops: correct error return on p_lstat failures when mkdir#5302
ethomson merged 1 commit into
libgit2:masterfrom
tiennou:fix/p_lstat-errno

Conversation

@tiennou

@tiennou tiennou commented Nov 9, 2019

Copy link
Copy Markdown
Contributor

IIRC I got a strange return once from lstat, which translated in a weird
error class/message being reported. As a safety measure, enforce a -1 return in
that case.

IIRC I got a strange return once from lstat, which translated in a weird
error class/message being reported. As a safety measure, enforce a -1 return in
that case.
@ethomson

ethomson commented Nov 9, 2019

Copy link
Copy Markdown
Member

LGTM. I don't think we would ever want to stop here and not report an error back to the caller. Either we ignore it (like in the ENOENT case) or we error. The current behavior definitely seems like a bug.

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.

3 participants