summaryrefslogtreecommitdiff
path: root/ext/standard/filestat.c
diff options
context:
space:
mode:
authorStanislav Malyshev <stas@php.net>2000-12-03 13:42:54 +0000
committerStanislav Malyshev <stas@php.net>2000-12-03 13:42:54 +0000
commit5b47d1ef7a6d6c12dd1f692cd1cfa14f3089444f (patch)
tree57a8a905b7cee6439e581a2cce5e2796e342c072 /ext/standard/filestat.c
parent3f38d892c0e045a59fa94a143b8c684240819919 (diff)
downloadphp-git-5b47d1ef7a6d6c12dd1f692cd1cfa14f3089444f.tar.gz
Fix #8079 - filetype now knows about sockets
Diffstat (limited to 'ext/standard/filestat.c')
-rw-r--r--ext/standard/filestat.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c
index e845f4872e..6935834d85 100644
--- a/ext/standard/filestat.c
+++ b/ext/standard/filestat.c
@@ -551,6 +551,9 @@ static void php_stat(const char *filename, int type, pval *return_value)
case S_IFDIR: RETURN_STRING("dir",1);
case S_IFBLK: RETURN_STRING("block",1);
case S_IFREG: RETURN_STRING("file",1);
+#ifndef ZEND_WIN32
+ case S_IFSOCK: RETURN_STRING("socket",1);
+#endif
}
php_error(E_WARNING,"Unknown file type (%d)",BG(sb).st_mode&S_IFMT);
RETURN_STRING("unknown",1);