diff options
author | 2015-01-13 01:12:59 +0000 | |
---|---|---|
committer | 2015-01-13 01:13:00 +0000 | |
commit | 595ae39f7f484eb5d2d9e21feeff7e97114b744a (patch) | |
tree | bd2b74790281c07c87ee7b7ee58c9571d9b2a01e /libs/androidfw/misc.cpp | |
parent | 21454aa27643f69a0ee9377ae09a01e96af3718f (diff) | |
parent | 1bf248123399daf8d4bee9c30ba13b9887e5001e (diff) |
Merge "Use more intention-revealing tests for S_ISLNK and S_ISSOCK."
Diffstat (limited to 'libs/androidfw/misc.cpp')
-rw-r--r-- | libs/androidfw/misc.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libs/androidfw/misc.cpp b/libs/androidfw/misc.cpp index 29686efe3753..a9b46d2808f2 100644 --- a/libs/androidfw/misc.cpp +++ b/libs/androidfw/misc.cpp @@ -56,9 +56,11 @@ FileType getFileType(const char* fileName) return kFileTypeBlockDev; else if (S_ISFIFO(sb.st_mode)) return kFileTypeFifo; -#ifdef HAVE_SYMLINKS +#if defined(S_ISLNK) else if (S_ISLNK(sb.st_mode)) return kFileTypeSymlink; +#endif +#if defined(S_ISSOCK) else if (S_ISSOCK(sb.st_mode)) return kFileTypeSocket; #endif |