summaryrefslogtreecommitdiff
path: root/ext/standard/pageinfo.c
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2002-08-16 15:04:00 +0000
committerIlia Alshanetsky <iliaa@php.net>2002-08-16 15:04:00 +0000
commit3bd899ea43fe2b6604562485a018e31e56ba12b5 (patch)
treed840b3ad9142fc4d017d154500fbe549114a2b00 /ext/standard/pageinfo.c
parent980feb5e98c3ff440417d6a424e5e4e06b2b195f (diff)
downloadphp-git-3bd899ea43fe2b6604562485a018e31e56ba12b5.tar.gz
Fixed a compile failure in Win32 caused by previous patch.
Changed else statement to comply with PHP coding standards.
Diffstat (limited to 'ext/standard/pageinfo.c')
-rw-r--r--ext/standard/pageinfo.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/ext/standard/pageinfo.c b/ext/standard/pageinfo.c
index 13d500bef7..e080e23233 100644
--- a/ext/standard/pageinfo.c
+++ b/ext/standard/pageinfo.c
@@ -31,6 +31,19 @@
#include <pwd.h>
#endif
#endif
+#if HAVE_GRP_H
+# ifdef PHP_WIN32
+# include "win32/grp.h"
+# else
+# include <grp.h>
+# endif
+#endif
+#ifdef PHP_WIN32
+#undef getgid
+#define getgroups(a, b) 0
+#define getgid() 1
+#define getuid() 1
+#endif
#if HAVE_UNISTD_H
#include <unistd.h>
#endif
@@ -56,8 +69,7 @@ PHPAPI void php_statpage(TSRMLS_D)
BG(page_gid) = pstat->st_gid;
BG(page_inode) = pstat->st_ino;
BG(page_mtime) = pstat->st_mtime;
- }
- else { /* handler for situations where there is no source file, ex. php -r */
+ } else { /* handler for situations where there is no source file, ex. php -r */
BG(page_uid) = getuid();
BG(page_gid) = getgid();
}