Chromium Code Reviews| Index: runtime/bin/directory_android.cc |
| diff --git a/runtime/bin/directory_android.cc b/runtime/bin/directory_android.cc |
| index 49077a325ec280cb261c4f88e4473c51ccb8f66b..36b458186089ed3bb3c6ba711ca2720e8bd82be0 100644 |
| --- a/runtime/bin/directory_android.cc |
| +++ b/runtime/bin/directory_android.cc |
| @@ -351,6 +351,9 @@ Directory::ExistsResult Directory::Exists(const char* dir_name) { |
| if (S_ISDIR(entry_info.st_mode)) { |
| return EXISTS; |
| } else { |
| + // An OSError may be constructed based on the return value of this |
| + // function, so set errno to something that makes sense. |
| + errno = ENOENT; |
|
rmacnak
2016/12/17 00:06:14
Consider ENOTDIR.
zra
2016/12/17 04:58:06
Done.
|
| return DOES_NOT_EXIST; |
| } |
| } else { |