| Index: runtime/bin/directory_linux.cc
|
| diff --git a/runtime/bin/directory_linux.cc b/runtime/bin/directory_linux.cc
|
| index 357a580e00681af00d9011600935feefc96c31f8..f2a064aeca8c8e8c452c920a969f4b23bf3c9f2e 100644
|
| --- a/runtime/bin/directory_linux.cc
|
| +++ b/runtime/bin/directory_linux.cc
|
| @@ -360,6 +360,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 = ENOTDIR;
|
| return DOES_NOT_EXIST;
|
| }
|
| } else {
|
|
|