#21396 [NEW]: after $var =pack(...) with 'N' flag, if use $var in $tmp[$var]='v' key is empty

2003-01-03 Thread slach
From: [EMAIL PROTECTED]
Operating system: w2k, linux
PHP version:  4.2.3
PHP Bug Type: Arrays related
Bug description:  after $var =pack(...) with 'N' flag, if use $var in $tmp[$var]='v' 
key is empty

just see code
?
error_reporting(E_ALL);

$aa = pack(N,127);
$bb = pack(N,65);
$cc = pack(N,121344231);

echo $aa\n;
echo $bb\n;
echo $cc\n;

$tmp=array();

$tmp[$aa] = aa;
$tmp[$bb] = bb;
$tmp[$cc] = cc;

var_dump($tmp);
?

output:

A
;Ð÷
array(3) {
  []=
  string(2) aa
^^^ but needed [] = aa ???
  []=
  string(2) bb
  [;Ð÷]=
  string(2) cc
}

WHY ?
-- 
Edit bug report at http://bugs.php.net/?id=21396edit=1
-- 
Try a CVS snapshot: http://bugs.php.net/fix.php?id=21396r=trysnapshot
Fixed in CVS:   http://bugs.php.net/fix.php?id=21396r=fixedcvs
Fixed in release:   http://bugs.php.net/fix.php?id=21396r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=21396r=needtrace
Try newer version:  http://bugs.php.net/fix.php?id=21396r=oldversion
Not developer issue:http://bugs.php.net/fix.php?id=21396r=support
Expected behavior:  http://bugs.php.net/fix.php?id=21396r=notwrong
Not enough info:http://bugs.php.net/fix.php?id=21396r=notenoughinfo
Submitted twice:http://bugs.php.net/fix.php?id=21396r=submittedtwice
register_globals:   http://bugs.php.net/fix.php?id=21396r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=21396r=php3
Daylight Savings:   http://bugs.php.net/fix.php?id=21396r=dst
IIS Stability:  http://bugs.php.net/fix.php?id=21396r=isapi
Install GNU Sed:http://bugs.php.net/fix.php?id=21396r=gnused




Bug #16186 Updated: include path in the module version, using sub dir as php causing error

2002-05-04 Thread slach

 ID:   16186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: *General Issues
 Operating System: Win2k
 PHP Version:  4.1.2
 New Comment:

for win32 php4.2.0+Apache1.3.x platform
replace in httd.conf DocumentRoot path like /usr/... on  c:/usr/...
(with drive literal)

but in this configuration not work correct mod_rewrite


Previous Comments:


[2002-04-16 03:54:57] [EMAIL PROTECTED]

I've the same problem
i've test php 4.1.2, 4.2.0rc3 , 4.2.0rc4.[Tue Apr 16 

My msg is:
09:45:42 2002] [error] PHP Warning:  Failed opening '/serveur
web/apache/htdocs/info.php' for inclusion (include_path='.;c:\serveur
web\php-4.2.0RC4-win32\pear') in Unknown on line 0



[2002-04-09 05:04:13] [EMAIL PROTECTED]

This problem doesn't exists on Windows XP as i can see



[2002-04-09 05:02:02] [EMAIL PROTECTED]

I have a similar problem but only with pages that contain phpinfo()

If i activate the include_path in the php.ini ALL scripts give the same
error (Warning: failed opening), if i comment out the
include_path instead only phpinfo() gives this error but the other
functions work fine

System is: 
Win 2000 Server sp2, Security Rollup Patch 1, all the patches founded
by HFNETCHK.exe were installed.
PHP 4.1.2 as ISAPI with php.ini-recommended
IIS 5.0 with all patches.



[2002-03-20 10:38:41] [EMAIL PROTECTED]

after I upgrade to 4.1.2 from 4.1.1 the php module version of Apache
stop working
all my working php script would throw an error

Warning: Failed opening 'path_of_the_script' for inclusion
(include_path='c:\php4\pear') in Unknown on line 0

even the one that doesn't require the use of include or require
function. In fact one of the script only have phpinfo() in it.

I've try to play around with the include_path however this make no
different.
I add my comment to a bogus post and also a Analyzed post so I thought
I would post it again

Anyway I move to the cgi version and get it to work fine, however I
found another bug, when I use a sub directly with the name php
immediate after the webroot any php page in that directly then Apache
will throw a not found error

Not Found
The requested URL /php/test.php was not found on this server.

I check in the log and this is what I found
[Wed Mar 20 10:37:18 2002] [error] [client 192.168.1.101] (2)No such
file or directory: script not found or unable to stat: c:/php/test.php

It seem to me that because I name the directory php, somehow it confuse
php and it start to pick up the page from c:\php which is where I
install php and not from the webroot.




-- 
Edit this bug report at http://bugs.php.net/?id=16186edit=1