svn: /php/php-src/ branches/PHP_5_2/main/main.c branches/PHP_5_3/main/main.c trunk/main/main.c
| From: | Dmitry Stogov | Date: | Tue, 08 Dec 2009 10:16:38 +0000 |
| Subject: | svn: /php/php-src/ branches/PHP_5_2/main/main.c branches/PHP_5_3/main/main.c trunk/main/main.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-61186@lists.php.net to get a copy of this message | ||
dmitry Tue, 08 Dec 2009 10:16:38 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=291871
Log:
- Forgotten patch for trunk
- Fixed stdin filename in error messages
Changed paths:
U php/php-src/branches/PHP_5_2/main/main.c
U php/php-src/branches/PHP_5_3/main/main.c
U php/php-src/trunk/main/main.c
Modified: php/php-src/branches/PHP_5_2/main/main.c
===================================================================
--- php/php-src/branches/PHP_5_2/main/main.c 2009-12-08 10:15:59 UTC (rev 291870)
+++ php/php-src/branches/PHP_5_2/main/main.c 2009-12-08 10:16:38 UTC (rev 291871)
@@ -1994,6 +1994,7 @@
* otherwise it will get opened and added to the included_files list in zend_execute_scripts
*/
if (primary_file->filename &&
+ (primary_file->filename[0] != '-' || primary_file->filename[1] != 0)
&&
primary_file->opened_path == NULL &&
primary_file->type != ZEND_HANDLE_FILENAME
) {
Modified: php/php-src/branches/PHP_5_3/main/main.c
===================================================================
--- php/php-src/branches/PHP_5_3/main/main.c 2009-12-08 10:15:59 UTC (rev 291870)
+++ php/php-src/branches/PHP_5_3/main/main.c 2009-12-08 10:16:38 UTC (rev 291871)
@@ -2191,6 +2191,7 @@
* otherwise it will get opened and added to the included_files list in zend_execute_scripts
*/
if (primary_file->filename &&
+ (primary_file->filename[0] != '-' || primary_file->filename[1] != 0)
&&
primary_file->opened_path == NULL &&
primary_file->type != ZEND_HANDLE_FILENAME
) {
Modified: php/php-src/trunk/main/main.c
===================================================================
--- php/php-src/trunk/main/main.c 2009-12-08 10:15:59 UTC (rev 291870)
+++ php/php-src/trunk/main/main.c 2009-12-08 10:16:38 UTC (rev 291871)
@@ -2311,12 +2311,14 @@
* otherwise it will get opened and added to the included_files list in zend_execute_scripts
*/
if (primary_file->filename &&
+ (primary_file->filename[0] != '-' || primary_file->filename[1] != 0)
&&
primary_file->opened_path == NULL &&
primary_file->type != ZEND_HANDLE_FILENAME
) {
int realfile_len;
int dummy = 1;
- if (VCWD_REALPATH(primary_file->filename, realfile)) {
+
+ if (expand_filepath(primary_file->filename, realfile TSRMLS_CC)) {
realfile_len = strlen(realfile);
zend_hash_add(&EG(included_files), realfile, realfile_len+1, (void *)&dummy,
sizeof(int), NULL);
primary_file->opened_path = estrndup(realfile, realfile_len);