ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> php-dev
php-dev
#44943 [NEW]: Failed opening required
by Krzysin At Gmail Dot Com other posts by this author
May 8 2008 1:50AM messages near this date
#44944 [Opn->WFx]: PHP Scope resolution operator | #44943 [Opn->Bgs]: Failed opening required
From:             krzysin at gmail dot com
Operating system: Linux
PHP version:      4.4.8
PHP Bug Type:     Scripting Engine problem
Bug description:  Failed opening required

Description:
------------
Failed opening required file, php 4, 5, ...

Reproduce code:
---------------
<?
require("2") || print "dd";
?> 


Expected result:
----------------
PHP Warning:  require(1): failed to open stream: No such file or directory
in /root/test.php on line 3

Warning: require(1): failed to open stream: No such file or directory in
/root/test.php on line 3
PHP Fatal error:  require(): Failed opening required '1'
(include_path='.:/usr/local/lib/php') in /root/test.php on line 3

Fatal error: require(): Failed opening required '1'
(include_path='.:/usr/local/lib/php') in /root/test.php on line 3


Actual result:
--------------
#0  0x37b62373 in fprintf () from /lib/libc.so.6
#1  0x08368ff9 in sapi_cli_log_message (
    message=0x37ad8ef8 "PHP Fatal error:  require(): Failed opening
required '1' (include_path='.:/usr/local/lib/php') in /root/test.php on
line 3")
    at /build/www/php5/php/sapi/cli/php_cli.c:313
#2  0x08278a18 in php_log_err (
    log_message=0x37ad8ef8 "PHP Fatal error:  require(): Failed opening
required '1' (include_path='.:/usr/local/lib/php') in
/root/krzysin/test.php on line 3")
    at /build/www/php5/php/main/main.c:505
#3  0x082794d3 in php_error_cb (type=64, error_filename=0x37ad8a38
"/root/test.php", error_lineno=3, format=0x8575e4c "%s", args=0x3fd23b9c)
    at /build/www/php5/php/main/main.c:904
#4  0x0817b5af in soap_error_handler (error_num=64,
error_filename=0x37ad8a38 "/root/test.php", error_lineno=3,
format=0x8575e4c "%s", args=0x3fd23b9c)
    at /build/www/php5/php/ext/soap/soap.c:2178
#5  0x082b9dbe in zend_error (type=64, format=0x8575e4c "%s") at
/build/www/php5/php/Zend/zend.c:967
#6  0x08279083 in php_verror (docref=0x8576231 "function.require",
params=0x8575c8e "", type=64, format=0x8576200 "Failed opening required
'%s' (include_path='%s')",
    args=0x3fd23c60) at /build/www/php5/php/main/main.c:721
#7  0x082790cb in php_error_docref0 (docref=0x8576231 "function.require",
type=64, format=0x8576200 "Failed opening required '%s'
(include_path='%s')")
    at /build/www/php5/php/main/main.c:733
#8  0x08279c6e in php_message_handler_for_zend (message=2,
data=0x37ad8cb8) at /build/www/php5/php/main/main.c:1119
#9  0x082b9c50 in zend_message_dispatcher (message=2, data=0x37ad8cb8) at
/build/www/php5/php/Zend/zend.c:894
#10 0x0829960d in compile_file (file_handle=<incomplete type> , type=8) at
/build/www/php5/php/Zend/zend_language_scanner.c:3410
#11 0x082997a8 in compile_filename (type=8, filename=0x3fd24e7c) at
/build/www/php5/php/Zend/zend_language_scanner.c:3465
#12 0x082e5b6e in ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER
(execute_data=0x3fd24efc) at
/build/www/php5/php/Zend/zend_vm_execute.h:4583
#13 0x082d5c0e in execute (op_array=0x37ad896c) at
/build/www/php5/php/Zend/zend_vm_execute.h:92
#14 0x082ba242 in zend_execute_scripts (type=8, retval=0x0, file_count=3)
at /build/www/php5/php/Zend/zend.c:1134
#15 0x0827afa1 in php_execute_script (primary_file=0x3fd27264) at
/build/www/php5/php/main/main.c:2005
#16 0x0836a404 in main (argc=2, argv=0x3fd272f4) at
/build/www/php5/php/sapi/cli/php_cli.c:1140


-- 
Edit bug report at http://bugs.php.net/?id=44943&edit=1
-- 
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=44943&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=44943&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=44943&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=44943&r=fixedcvs
Fixed in release:             http://bugs.php.net/fix.php?id=44943&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=44943&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=44943&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=44943&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=44943&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=44943&r=notwrong
Not enough info:              http://bugs.php.net/fix.php?id=44943&r=notenoughinfo
Submitted twice:              http://bugs.php.net/fix.php?id=44943&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=44943&r=globals
PHP 4 support discontinued:   http://bugs.php.net/fix.php?id=44943&r=php4
Daylight Savings:             http://bugs.php.net/fix.php?id=44943&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=44943&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=44943&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=44943&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=44943&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=44943&r=mysqlcfg
Thread:
Krzysin At Gmail Dot Com
felipe

Privacy Policy | Email Opt-out | Feedback | Syndication
© 2004 ActiveState, a division of Sophos All rights reserved