cvs: php4 /ext/standard pageinfo.c
| From: | Ilia Alshanetsky | Date: | Fri, 16 Aug 2002 15:04:00 +0000 |
| Subject: | cvs: php4 /ext/standard pageinfo.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-13413@lists.php.net to get a copy of this message | ||
iliaa Fri Aug 16 11:04:00 2002 EDT
Modified files:
/php4/ext/standard pageinfo.c
Log:
Fixed a compile failure in Win32 caused by previous patch.
Changed else statement to comply with PHP coding standards.
Index: php4/ext/standard/pageinfo.c
diff -u php4/ext/standard/pageinfo.c:1.31 php4/ext/standard/pageinfo.c:1.32
--- php4/ext/standard/pageinfo.c:1.31 Fri Aug 16 08:47:56 2002
+++ php4/ext/standard/pageinfo.c Fri Aug 16 11:04:00 2002
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: pageinfo.c,v 1.31 2002/08/16 12:47:56 iliaa Exp $ */
+/* $Id: pageinfo.c,v 1.32 2002/08/16 15:04:00 iliaa Exp $ */
#include "php.h"
#include "pageinfo.h"
@@ -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 @@
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();
}