diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2002-08-16 12:47:56 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2002-08-16 12:47:56 +0000 |
commit | f11c3a409558f6159d88b5c876976064f51fc469 (patch) | |
tree | 3cf70b846fc8399e4d79f6d311affc0a0a0c9a89 | |
parent | 2e4b6ef181934b893001723f3cbec091d23e9bbd (diff) | |
download | php-git-f11c3a409558f6159d88b5c876976064f51fc469.tar.gz |
Added a handler for php -r '' for SAFE_MODE
-rw-r--r-- | ext/standard/pageinfo.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/standard/pageinfo.c b/ext/standard/pageinfo.c index e1ea9c54f2..13d500bef7 100644 --- a/ext/standard/pageinfo.c +++ b/ext/standard/pageinfo.c @@ -35,6 +35,7 @@ #include <unistd.h> #endif #include <sys/stat.h> +#include <sys/types.h> #ifdef PHP_WIN32 #include <process.h> #endif @@ -56,6 +57,10 @@ PHPAPI void php_statpage(TSRMLS_D) 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 */ + BG(page_uid) = getuid(); + BG(page_gid) = getgid(); + } } } /* }}} */ |