From 43b75c6ab4f54d9671e95ca6bf653efd938e999a Mon Sep 17 00:00:00 2001 From: Brian France Date: Fri, 10 Mar 2006 18:16:24 +0000 Subject: [PATCH] for the primary file only lookup the real file path and add it to the included_files list if already opened otherwise it will get opened and added to the included_files list in zend_execute_scripts --- main/main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main/main.c b/main/main.c index 63d6f00b980..671a20fdca2 100644 --- a/main/main.c +++ b/main/main.c @@ -1786,7 +1786,10 @@ PHPAPI int php_execute_script(zend_file_handle *primary_file TSRMLS_DC) VCWD_CHDIR_FILE(primary_file->filename); } - if (primary_file->filename) { + /* Only lookup the real file path and add it to the included_files list if already opened + * otherwise it will get opened and added to the included_files list in zend_execute_scripts + */ + if (primary_file->filename && primary_file->type != ZEND_HANDLE_FILENAME) { int realfile_len; int dummy = 1; if (VCWD_REALPATH(primary_file->filename, realfile)) {