Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread derick

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus


Previous Comments:


[2002-05-16 22:23:02] [EMAIL PROTECTED]

This problem also occurs on PHP 4.1.2.

The following code fragment produces very odd results:

?
$a = array(41.96, 20.97, 20.99);
$t = 0;
for($i = 1; $i  count($a); $i++)
$t += abs($a[$i]);
echo $t != $a[0]\n;
var_dump($t != $a[0]);
echo t = ;
var_dump($t);
echo a[0] = ;
var_dump($a[0]);
?

The results are shown below:

41.96 != 41.96
bool(true)
t = float(41.96)
a[0] = float(41.96)

Both variables appear to be the same type, and look the same, yet
compare incorrectly with both typed and untyped comparisons.





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




Bug #14999 Updated: apache_lookup_uri returning array for apache2 instead of object

2002-05-17 Thread jwoolley

 ID:   14999
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Apache2 related
-Operating System: linux
+Operating System: All
-PHP Version:  4.1.1
+PHP Version:  4.2.1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.

I committed a variant of your patch.  Same idea, just done with the
existing macros to reduce diff (and code) verbosity.  I had to account
for the fact that rr-request_time and rr-mtime are apr_time_t's
(microseconds) now rather than time_t's (seconds) as well.  It should
now be the case that the only difference between apache 2.0's
apache_lookup_uri() and apache 1.3's are the missing byterange and
boundary fields (boundary just now disappeared as of 2.0.37).  Is it
worth having those in there with wrong (zero) values?  Or should we
just leave them out and document that they're gone?  Send me an email
if you have an opinion on the matter.  Thanks!


Previous Comments:


[2002-02-18 12:49:53] [EMAIL PROTECTED]

What about this patch ?
has someone try it ?
what is the way of apache2 fonction ? 
keep the maximum of backwards compatibility ?




[2002-01-23 17:36:04] [EMAIL PROTECTED]

The Apache request_rec struct has many change between version 1.3 and
2.0. perhaps we should rename this fonction in apache2_lookup_uri

for example the byterange has desapear

here is the patch to be more compatible with apache 1.3 version  

PHP_FUNCTION(apache_lookup_uri)
{
pval **filename;
request_rec *rr=NULL;

rr = php_apache_lookup_uri(INTERNAL_FUNCTION_PARAM_PASSTHRU);
if (!rr)
WRONG_PARAM_COUNT;

object_init(return_value);
add_property_long(return_value,status, rr-status);
if (rr-the_request) {
add_property_string(return_value,the_request,
rr-the_request, 1);
}
if (rr-status_line) {
add_property_string(return_value,status_line, (char
*)rr-status_line, 1);
}
if (rr-method) {
add_property_string(return_value,method, (char
*)rr-method, 1);  
}
if (rr-content_type) {
add_property_string(return_value,content_type, (char
*)rr-content_type, 1);
}
if (rr-handler) {
add_property_string(return_value,handler, (char
*)rr-handler, 1);
}
if (rr-uri) {
add_property_string(return_value,uri, rr-uri, 1);
}
if (rr-filename) {
add_property_string(return_value,filename,
rr-filename, 1);
}
if (rr-path_info) {
add_property_string(return_value,path_info,
rr-path_info, 1);
}
if (rr-args) {
add_property_string(return_value,args, rr-args, 1);
}
if (rr-range) {
add_property_string(return_value,range,(char
*)rr-range, 1);
}
if (rr-boundary) {
add_property_string(return_value,boundary,(char
*)rr-boundary, 1);
}
add_property_long(return_value,no_cache, rr-no_cache);
add_property_long(return_value,no_local_copy,
rr-no_local_copy);
add_property_long(return_value,allowed, rr-allowed);
add_property_long(return_value,sent_bodyct,
rr-sent_bodyct);
add_property_long(return_value,bytes_sent, rr-bytes_sent);
add_property_long(return_value,clength, rr-clength);

#if MODULE_MAGIC_NUMBER = 19980324
if (rr-unparsed_uri) {
add_property_string(return_value,unparsed_uri,
rr-unparsed_uri, 1);
}
if(rr-mtime) {
add_property_long(return_value,mtime, rr-mtime);
}
#endif
if(rr-request_time) {
add_property_long(return_value,request_time,
rr-request_time);
}
ap_destroy_sub_req(rr);
}



















[2002-01-11 12:59:34] [EMAIL PROTECTED]

this is simple: apache_lookup_uri is returning array on apache2 instead
of object (as it is doing on apache 1.3 and as it is written in
documentation). the array is filled good with right keys and values,
only problem is that it is array and not object





-- 
Edit this bug report at 

Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread david

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.


Previous Comments:


[2002-05-17 02:16:22] [EMAIL PROTECTED]

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus



[2002-05-16 22:23:02] [EMAIL PROTECTED]

This problem also occurs on PHP 4.1.2.

The following code fragment produces very odd results:

?
$a = array(41.96, 20.97, 20.99);
$t = 0;
for($i = 1; $i  count($a); $i++)
$t += abs($a[$i]);
echo $t != $a[0]\n;
var_dump($t != $a[0]);
echo t = ;
var_dump($t);
echo a[0] = ;
var_dump($a[0]);
?

The results are shown below:

41.96 != 41.96
bool(true)
t = float(41.96)
a[0] = float(41.96)

Both variables appear to be the same type, and look the same, yet
compare incorrectly with both typed and untyped comparisons.





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




Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread derick

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

Actually this is documented:
http://www.php.net/manual/en/language.types.float.php

 I am well aware that there can be errors due to loss of precision,
but
 in that case, the number should not appear to be _exactly the same_.
 There should be some way to tell that they are different.

You can tell they are different by comparing them, which obviously
almost always fails, but i fyou do this:

if (41.96 == 41.96)

it will return true ofcourse.

There was some discussion on this topic before, and the consensus of
the list was not to change anything related to this.

regards,
Derick


Previous Comments:


[2002-05-17 02:36:19] [EMAIL PROTECTED]

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.



[2002-05-17 02:16:22] [EMAIL PROTECTED]

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus



[2002-05-16 22:23:02] [EMAIL PROTECTED]

This problem also occurs on PHP 4.1.2.

The following code fragment produces very odd results:

?
$a = array(41.96, 20.97, 20.99);
$t = 0;
for($i = 1; $i  count($a); $i++)
$t += abs($a[$i]);
echo $t != $a[0]\n;
var_dump($t != $a[0]);
echo t = ;
var_dump($t);
echo a[0] = ;
var_dump($a[0]);
?

The results are shown below:

41.96 != 41.96
bool(true)
t = float(41.96)
a[0] = float(41.96)

Both variables appear to be the same type, and look the same, yet
compare incorrectly with both typed and untyped comparisons.





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




Bug #16626 Updated: Only last cookie set

2002-05-17 Thread jwoolley

 ID:   16626
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Apache2 related
-Operating System: RedHat 7.2 (kernel 2.4.18) i386
+Operating System: All
-PHP Version:  4.2.0
+PHP Version:  4.2.1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.

Patch committed.  Thanks, regina!


Previous Comments:


[2002-05-12 15:17:09] [EMAIL PROTECTED]

Just ran into this problem as i was running apache 2 under win2k with
php 4.2.0 installed as apache module. No Cookie seemed to be set
correctly. I solved this problem by running PHP as CGI binary.



[2002-05-03 01:11:05] [EMAIL PROTECTED]

I did fix this problem by modifing ext/standard/head.c.
The diff is below.

124c124
   return sapi_add_header(cookie, strlen(cookie), 0);
---
   return sapi_add_header_ex(cookie, strlen(cookie), 0, 0
TSRMLS_CC);


PS) This bug should be killed at next version. May be



[2002-04-26 16:00:46] [EMAIL PROTECTED]

Yeap I have the same problem ... 

Very interessting is, sometimes works.

For Example: I have written a Bulletin Board, so I can't Login (with
Cookie) my wife have no problem ... I don't know why.



[2002-04-25 00:44:01] [EMAIL PROTECTED]

I just want to add, that this is a apache 2.0 compatiblity bug, I'm
sure you all tested this out on apache 1.3.24 and it works fine for me.
so I think with the shtml bugs that apache is having this could be
included with that issue.



[2002-04-24 15:13:00] [EMAIL PROTECTED]

I can confirm that the replacement function for setcookie by
[EMAIL PROTECTED] (send_htCookie) just sets the last cookie in the HTTP
response header on my system



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/16626

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




Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread corey

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

Ah, but the source is very interesting.

?
$b = 41.00;
$b2 = 00.96;

$c = array(41.96,41.00,00.96,0.00,41.96);
for($i=1;$i3;$i++)
 $c[3]+=$c[$i];

echo p;
var_dump($c[3] != $c[0]);

echo p;
var_dump($c[4] != $c[0]);

echo p;
$b2 = $b + $b2;
var_dump($c[0] != $b2);

echo p;
var_dump($c[3] != $b2);
?

OUTPUT:

bool(false) 

bool(false) 

bool(false) 

bool(false) 

Why is it those 2 numbers only?


Previous Comments:


[2002-05-17 02:41:23] [EMAIL PROTECTED]

Actually this is documented:
http://www.php.net/manual/en/language.types.float.php

 I am well aware that there can be errors due to loss of precision,
but
 in that case, the number should not appear to be _exactly the same_.
 There should be some way to tell that they are different.

You can tell they are different by comparing them, which obviously
almost always fails, but i fyou do this:

if (41.96 == 41.96)

it will return true ofcourse.

There was some discussion on this topic before, and the consensus of
the list was not to change anything related to this.

regards,
Derick



[2002-05-17 02:36:19] [EMAIL PROTECTED]

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.



[2002-05-17 02:16:22] [EMAIL PROTECTED]

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus



[2002-05-16 22:23:02] [EMAIL PROTECTED]

This problem also occurs on PHP 4.1.2.

The following code fragment produces very odd results:

?
$a = array(41.96, 20.97, 20.99);
$t = 0;
for($i = 1; $i  count($a); $i++)
$t += abs($a[$i]);
echo $t != $a[0]\n;
var_dump($t != $a[0]);
echo t = ;
var_dump($t);
echo a[0] = ;
var_dump($a[0]);
?

The results are shown below:

41.96 != 41.96
bool(true)
t = float(41.96)
a[0] = float(41.96)

Both variables appear to be the same type, and look the same, yet
compare incorrectly with both typed and untyped comparisons.





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




Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread corey

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

sorry, didn't see your earlier update.

However, I'd just like to comment that it is rediculous that a feature
exists that is known to be false.


Previous Comments:


[2002-05-17 03:22:55] [EMAIL PROTECTED]

Ah, but the source is very interesting.

?
$b = 41.00;
$b2 = 00.96;

$c = array(41.96,41.00,00.96,0.00,41.96);
for($i=1;$i3;$i++)
 $c[3]+=$c[$i];

echo p;
var_dump($c[3] != $c[0]);

echo p;
var_dump($c[4] != $c[0]);

echo p;
$b2 = $b + $b2;
var_dump($c[0] != $b2);

echo p;
var_dump($c[3] != $b2);
?

OUTPUT:

bool(false) 

bool(false) 

bool(false) 

bool(false) 

Why is it those 2 numbers only?



[2002-05-17 02:41:23] [EMAIL PROTECTED]

Actually this is documented:
http://www.php.net/manual/en/language.types.float.php

 I am well aware that there can be errors due to loss of precision,
but
 in that case, the number should not appear to be _exactly the same_.
 There should be some way to tell that they are different.

You can tell they are different by comparing them, which obviously
almost always fails, but i fyou do this:

if (41.96 == 41.96)

it will return true ofcourse.

There was some discussion on this topic before, and the consensus of
the list was not to change anything related to this.

regards,
Derick



[2002-05-17 02:36:19] [EMAIL PROTECTED]

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.



[2002-05-17 02:16:22] [EMAIL PROTECTED]

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus



[2002-05-16 22:23:02] [EMAIL PROTECTED]

This problem also occurs on PHP 4.1.2.

The following code fragment produces very odd results:

?
$a = array(41.96, 20.97, 20.99);
$t = 0;
for($i = 1; $i  count($a); $i++)
$t += abs($a[$i]);
echo $t != $a[0]\n;
var_dump($t != $a[0]);
echo t = ;
var_dump($t);
echo a[0] = ;
var_dump($a[0]);
?

The results are shown below:

41.96 != 41.96
bool(true)
t = float(41.96)
a[0] = float(41.96)

Both variables appear to be the same type, and look the same, yet
compare incorrectly with both typed and untyped comparisons.





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




Bug #16698 Updated: phpinfo() hangs

2002-05-17 Thread jwoolley

 ID:   16698
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Apache2 related
 Operating System: Windows XP Pro
 PHP Version:  4.2.0
 New Comment:

I'm having trouble reproducing this problem on Linux, with either the
threaded or non-threaded MPMs.  (Yes, I know you said you saw it on
WinXP.)  Can you generate a backtrace on this somehow?  Interrupt the
httpd task that's running out of control with MSVC's debugger and find
out what it's up to?  (Sorry I can't be much more specific on this, I
don't know much about MSVC.)  I assume you read 
http://www.apache.org/dist/httpd/binaries/win32/#xpbug , right?

Thanks,
Cliff


Previous Comments:


[2002-04-21 18:56:59] [EMAIL PROTECTED]

From reading other bugs about corrupted output on XP systems, i tried
one of the WORK AROUNDS that do not fix the problem, but hide it (which
is good enough for me untill an actual fix is found).

I did the suggested (and disputed by php.net) method of having the
content gzipped. It does HIDE the problem (in their bug and in mine).
But like php.net said, it is not recomended.

phpinfo() does not hang, and i have no corrupted output, with gzip on.



[2002-04-19 10:28:23] [EMAIL PROTECTED]

a php file containing nothing but:

?

phpinfo();

?

loads about halfway, then stops. the server running php+apache then
goes into 5 second freezes and 5 second 100% usage peaks. These
happens consistantly and hoses the system untill all other processes
cant function.

The error logs show nothing, and the event viewer (windows)shows
nothing. It also happens when i use:

show_source(php_script.php);

on a fairly small script.

I am using the Apache2filter test module.

I can't currently show you an example of this becuase: my server just
went down, and im at work (it's at home) and it would crash if i showed
you! When i get home i will recreate the bug a 3rd time to make sure im
not crazy.




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




Bug #17005 Updated: Configure failure using apxs2

2002-05-17 Thread jwoolley

 ID:   17005
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: RedHat 7.2
 PHP Version:  4.0CVS-2002-05-04
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.

I'm going to assume the apxs bug that was mentioned in this report
really was the problem and close this out.  If you find that it still
doesn't work with Apache 2.0.37, please feel free to open a new report.
 Thanks!


Previous Comments:


[2002-05-15 07:27:49] [EMAIL PROTECTED]

I think this might be the cause of a bug in the apxs script. It fails
when sbindir != bindir

Have a look at my report in apaches bug db:
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8869

The fix will be included in apache 2.0.37, if you want to try it
already there's a patch in the report above.



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

I have tried running the configure script on both the current download
version of php4 and also the latest CVS version. 
The compile script stops when it checks for apxs.

I used the following command on both occations:
./configure --with-mysql --with-apxs2=/usr/sbin/apxs

I have re-compiled apache-2.0.35 several times in the belief that there
was a problem with the installation.
The configure command used for apache is:
./configure --enable-layout=RedHat --enable-ssl=shared
--enable-disk-cache --enable-mem-cache --enable-mods-shared=all
Apache compiles successfuly and works as expected.

The end of the php4 configure script follows: 
...
Configuring SAPI modules
checking for AOLserver support... no
checking for Apache 1.x module support via DSO through APXS... no
checking for Apache 1.x module support... no
checking for mod_charset compatibility option... no
checking for Apache 2.0 module support via DSO through APXS...

Sorry, I cannot run apxs.  Possible reasons follow:

1. Perl is not installed
2. apxs was not found. Try to pass the path using
--with-apxs2=/path/to/apxs
3. Apache was not built using --enable-so (the apxs usage page is
displayed)

The output of /usr/sbin/apxs follows:
Usage: apxs -g [-S var=val] -n modname
   apxs -q [-S var=val] query ...
   apxs -c [-S var=val] [-o dsofile] [-D name[=value]]
   [-I incdir] [-L libdir] [-l libname]
[-Wc,flags]
   [-Wl,flags] files ...
   apxs -i [-S var=val] [-a] [-A] [-n modname] dsofile ...
   apxs -e [-S var=val] [-a] [-A] [-n modname] dsofile ...
configure: error: Aborting



Thanks in advance.
Yours,

Andy B




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




Bug #17234 Updated: setting short_open_tag in .htaccess does nothing

2002-05-17 Thread jwoolley

 ID:   17234
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Apache2 related
 Operating System: Windows XP
 PHP Version:  4.2.1
 New Comment:

That last problem you mentioned (Invalid command 'php_flag') is fixed
in CVS, just so you know.


Previous Comments:


[2002-05-15 19:28:19] [EMAIL PROTECTED]

Error message: 
directory/.htaccess: Invalid command 'php_flag', perhaps mis-spelled
or defined by a module not included in the server configuration.

This isn't bogus yet.



[2002-05-15 14:41:15] [EMAIL PROTECTED]

You need php_flag for on/off settings:
php_flag short_open_tag off



[2002-05-15 00:39:18] [EMAIL PROTECTED]

Sorry, module.

I've tried other values such as display_errors and that changes fine.



[2002-05-15 00:32:23] [EMAIL PROTECTED]

CGI or Apache module?  The CGI version of PHP does not read .htaccess.



[2002-05-14 23:45:19] [EMAIL PROTECTED]

Entering a value for short_open_tag in the .htaccess file achieves
nothing. Example:

php_value short_open_tag X

Where X is 0, 1, off, on, true, false, etc. Executing phpinfo() will
reveal the local value does not change from the master value, whether
the master value is on or off.

I'd like to keep short_open_tag on for the majority of sites I'm
running on my server but there is one in particular making use of XML
which I want to disable short_open_tag for.




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




Bug #17233 Updated: PHP 4.2.x apache2filter does not recognize -dev versions

2002-05-17 Thread jwoolley

 ID:   17233
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Solaris
 PHP Version:  4.2.1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.

Huh, what awk do you have?  gawk doesn't seem to care about the -dev (I
get 237 as expected, even with the -dev).  Oh well, the patch
doesn't hurt anything either, so I went ahead an applied it.  Done for
apache 1.3 as well, btw.  Thanks!


Previous Comments:


[2002-05-14 21:52:13] [EMAIL PROTECTED]


sapi/apache2filter/config.m4 fails to recognize Apache 2.x.x-dev (CVS)
version strings and thus the test for Apache version gt 2.0.0 fails.

Attached is a patch to compensate for -dev being in the version
string.

*** config.m4.orig  Tue May 14 21:44:07 2002
--- config.m4   Tue May 14 21:42:52 2002
***
*** 34,40 
APXS_HTTPD=`$APXS -q SBINDIR`/`$APXS -q TARGET`

# Test that we're trying to configure with apache 2.x
!   APACHE_VERSION=`$APXS_HTTPD -v | head -1 | cut -f3 -d' ' | cut -f2
-d'/' | awk 'BEGIN { FS = .; } { printf %d, ($1 * 1000 + $2) * 1000
+ $3;}'`
if test $APACHE_VERSION -le 200; then
  AC_MSG_ERROR([Use --with-apxs with Apache 1.3.x!])
elif test $APACHE_VERSION -lt 235; then
--- 34,40 
APXS_HTTPD=`$APXS -q SBINDIR`/`$APXS -q TARGET`

# Test that we're trying to configure with apache 2.x
!   APACHE_VERSION=`$APXS_HTTPD -v | head -1 | cut -f3 -d' ' | cut -f2
-d'/' | cut -f1 -d'-' | awk 'BEGIN { FS = .; } { printf %d, ($1 *
1000 + $2) * 1000 + $3;}'`
if test $APACHE_VERSION -le 200; then
  AC_MSG_ERROR([Use --with-apxs with Apache 1.3.x!])
elif test $APACHE_VERSION -lt 235; then





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




Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread corey

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

You're right, floats aren't precise, but neither is your output. I
don't know if it is rounded or something odd, but if you say it
operates the same as in C, I challenge you to test adding 20.99 and
20.97 in C and compare it to 41.96.

You will find that they are not the same BUT c does the correct
response by outputting it's float value of 41.95 instead of 41.96

In your case, the comparison should be on the value that is used for
display and etc.


Previous Comments:


[2002-05-17 03:25:19] [EMAIL PROTECTED]

sorry, didn't see your earlier update.

However, I'd just like to comment that it is rediculous that a feature
exists that is known to be false.



[2002-05-17 03:22:55] [EMAIL PROTECTED]

Ah, but the source is very interesting.

?
$b = 41.00;
$b2 = 00.96;

$c = array(41.96,41.00,00.96,0.00,41.96);
for($i=1;$i3;$i++)
 $c[3]+=$c[$i];

echo p;
var_dump($c[3] != $c[0]);

echo p;
var_dump($c[4] != $c[0]);

echo p;
$b2 = $b + $b2;
var_dump($c[0] != $b2);

echo p;
var_dump($c[3] != $b2);
?

OUTPUT:

bool(false) 

bool(false) 

bool(false) 

bool(false) 

Why is it those 2 numbers only?



[2002-05-17 02:41:23] [EMAIL PROTECTED]

Actually this is documented:
http://www.php.net/manual/en/language.types.float.php

 I am well aware that there can be errors due to loss of precision,
but
 in that case, the number should not appear to be _exactly the same_.
 There should be some way to tell that they are different.

You can tell they are different by comparing them, which obviously
almost always fails, but i fyou do this:

if (41.96 == 41.96)

it will return true ofcourse.

There was some discussion on this topic before, and the consensus of
the list was not to change anything related to this.

regards,
Derick



[2002-05-17 02:36:19] [EMAIL PROTECTED]

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.



[2002-05-17 02:16:22] [EMAIL PROTECTED]

You can't compare floats like this, a float is an approximation of the
number, but never exact the number.
This is not a bug, this wouldn't work in most languages, including C -
Bogus



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/17282

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




Bug #16683 Updated: gdIOCtx

2002-05-17 Thread peter

 ID:   16683
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: GD related
 Operating System: Mac OS X
 PHP Version:  4.1.2
 New Comment:

I've just finished installing gd-1.8.4 and php 4.2.0 on Redhat linux.
After ecountering most of the install problems between PHP and GD
(including the typedef for gdIOCtx), I realised that the problem
appears to be that the configuration header file generated by the php
'configure' script is not actually included in to the C source... So
here's what I did:

- On my system, configure - main/php_config.h.
- I created a soft link to this file called main/config.h.
- I then edited the file 'config_vars.mk' and under CPP_FLAGS i added
-DHAVE_CONFIG_H=1. This extra flag tells the compiler to include the
'config.h' in the C files which have the lines #ifdef
HAVE_CONFIG_H;#include config.h;#endif of which there are quite a
number, including gd.c!
- After all that it compiled *perfectly*.

I look forward to hearing whether this is a problem with the configure
script, or whether there is a configuration setting which can be
changed to rectify this error.


Previous Comments:


[2002-04-23 10:44:31] [EMAIL PROTECTED]

This problem also appears in 4.2.0 just released.



[2002-04-19 02:53:43] [EMAIL PROTECTED]

Sorry I was in a rush. 

I have install GD 1.8.4 from source archive into /usr/local/.  There is
no other GD installed. As for PHP, it was configured as follows:

./configure \
--enable-bcmath \
--enable-ftp \
--enable-track-vars \
--with-apxs \
--with-gd \
--with-mm \
--with-openssl \
--with-snmp \
--with-zlib \
--without-tsrm-pthreads



[2002-04-18 16:39:28] [EMAIL PROTECTED]

They're not supposed to be same..
How did you configure PHP ? How did you configure / compile the GD
library? Do you have different versions of GD library
installed?




[2002-04-18 11:57:34] [EMAIL PROTECTED]

The types of gdIOCtx in 

/usr/local/include/gd_io.h

and 

/usr/local/src/php-4.1.2/ext/gd/gd.c (line 92)

Are in no way similar.

This is similar to 14271.




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




Bug #17275 Updated: IIS stop responding HTTP requests

2002-05-17 Thread sander

 ID:   17275
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: Reproducible crash
 Operating System: NT4 Server
 PHP Version:  4.2.1
 New Comment:

This is not a problem with PHP but a problem with IIS. Blame Microsoft.


Previous Comments:


[2002-05-16 15:35:13] [EMAIL PROTECTED]

I'm using the Microsoft WebStress Application Tool to test the
server, and when MANY requests are made at the same time, many
php.exe's are still running in the Task Manager but IIS stop
responding the requests. No Dr. Watson or any other type of error
occurs. It simple stop responding. If I made fewer requests, the IIS
responds to all of them and for all the time I want...




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




Bug #14051 Updated: Invalid return in realpath if extra slash

2002-05-17 Thread preston . bannister

 ID:   14051
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: *Directory/Filesystem functions
 Operating System: Windows
 PHP Version:  4.0.6
 New Comment:

Note that //tmp or \\tmp looks like a UNC path (due to the //
prefix), and therefore cannot be reduced.


Previous Comments:


[2001-11-20 10:39:33] [EMAIL PROTECTED]

In my opinion it's not the same problem as bug #14049 !?




[2001-11-14 04:56:53] [EMAIL PROTECTED]

Update the #14049 bug report. DO NOT OPEN NEW REPORTS ABOUT SAME
THING!!




[2001-11-14 04:53:26] [EMAIL PROTECTED]

?php
echo '['.realpath('//tmp').']';
?

On Windows : [/\tmp] - Correct : [c:\tmp]
On Linux   : [/tmp]





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




Bug #17285: ext/java/Makefile is broken, here is a fix

2002-05-17 Thread rmihailescu

From: [EMAIL PROTECTED]
Operating system: RedHat Linux 7.1 -- Customized
PHP version:  4.1.2
PHP Bug Type: Compile Failure
Bug description:  ext/java/Makefile is broken, here is a fix

Contents of /ftp/pub/linux/apache_modules/php.4.1.2.config.run:{
#!/bin/bash

./configure --with-apxs=/usr/sbin/apxs --with-mod_charset
--enable-force-cgi-redirect \
 --enable-discard-path --with-java --with-openssl=shared --enable-sigchild
--enable-magic-quotes\
 --with-zlib --enable-bcmath=shared --with-bz2 --enable-calendar=shared
--with-gdbm --with-ndbm --with-db2 \
 --with-db3 --enable-dbase=shared --enable-dba=shared --enable-dbx=shared
--enable-exif=shared --enable-filepro=shared --enable$
--enable-gd-native-ttf --with-ttf --with-gettext --with-imap
--with-iconv=shared --with-imap-ssl \
 --with-ldap=shared --enable-mailparse=shared --enable-mbstring=shared
--with-mysql=/usr --with-unixODBC=shared  --with-pgsql=s$
--with-pspell=shared --with-qtdom=shared --with-ncurses=shared
--enable-trans-sid --with-snmp=shared --enable-ucd-snmp-hack \
 --enable-sockets --enable-sysvsem --enable-sysvshm --enable-yp
--enable-versioning \
 --with-kerberos=shared --with-shared --with-experimental-zts
--enable-shared --with-interbase=shared,/opt/interbase
}

Contents of fixed file (ext/java/Makefile):{
# from @php.4.1.2.tar.gz unziptar/ext/java
# By @Dexter of Cancer Software a.k.a. Radu - Eosif Mihailescu
# Added -d. to javac line below to make it build under RedHat  Kaffe
# Some ppl were lame enough not to able to write a .java.class: line
:-D

# Also, the configure script forgot to add the -L/usr/kerberos/lib line
as well ...

top_srcdir   = /home/ftp/pub/i386-linux/apache_modules/php-4.1.2
top_builddir = /home/ftp/pub/i386-linux/apache_modules/php-4.1.2
srcdir   = /home/ftp/pub/i386-linux/apache_modules/php-4.1.2/ext/java
builddir = /home/ftp/pub/i386-linux/apache_modules/php-4.1.2/ext/java
VPATH= /home/ftp/pub/i386-linux/apache_modules/php-4.1.2/ext/java

LTLIBRARY_SHARED_NAME  = libphp_java.la
LTLIBRARY_SOURCES  = java.c
LTLIBRARY_DEPENDENCIES = php_java.jar

LTLIBRARY_LDFLAGS   = $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS)
-L/usr/kerberos/lib
LTLIBRARY_SHARED_LIBADD = $(LTLIBRARY_DEPENDENCIES) $(EXTRA_LIBS)

EXTRA_CFLAGS   = $(JAVA_CFLAGS)
EXTRA_INCLUDES = $(JAVA_INCLUDE)

make_shared = yes

include $(top_srcdir)/build/dynlib.mk

php_java.jar : reflect.java
$(mkinstalldirs) net/php
@cp $(srcdir)/reflect.java net/php
@echo library=php_javanet/php/reflect.properties
javac -d. net/php/reflect.java # bug in author of Makefile!
@test ! -f reflect.class || mv reflect.class net/php # bug in KJC
javac
$(JAVA_JAR) php_java.jar net/php/*.class net/php/*.properties
@rm net/php/reflect.*
@rmdir net/php
@rmdir net
}

Other details:{
Using Kaffe as JavaVM
}

Contact:{
[EMAIL PROTECTED] ; ICQ: 27762040
}

Regards,
Dexter
-- 
Edit bug report at http://bugs.php.net/?id=17285edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17285r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17285r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17285r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17285r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17285r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17285r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17285r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17285r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17285r=globals




Bug #17286: PHP4.2.1 fails to compile on Solaris 8 (02/02)

2002-05-17 Thread michel . jansens

From: [EMAIL PROTECTED]
Operating system: Solaris 8 (02/02)
PHP version:  4.2.1
PHP Bug Type: *Compile Issues
Bug description:  PHP4.2.1 fails to compile on Solaris 8 (02/02) 

./configure --with-apxs=/usr/products/apache/bin/apxs
make

Making all in Zend
/bin/sh ../libtool --silent --mode=compile gcc -DHAVE_CONFIG_H -I. -I.
-I../main-D_POSIX_PTHREAD_SEMANTICS -DSOLARIS2=280 -DMOD_SSL=208108
-DEAPI -DEAPI_MM -DUSE_EXPAT -I../TSRM  -g -O2 -prefer-pic -c -o
zend_language_parser.lo `test -f zend_language_parser.c || echo
'./'`zend_language_parser.c
In file included from zend_compile.h:24,
 from zend_language_parser.c:147:
zend.h:55: unix.h: No such file or directory
*** Error code 1
make: Fatal error: Command failed for target `zend_language_parser.lo'
Current working directory /usr/products/src/php-4.2.1/Zend
*** Error code 1
make: Fatal error: Command failed for target `all-recursive'

-- 
Edit bug report at http://bugs.php.net/?id=17286edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17286r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17286r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17286r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17286r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17286r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17286r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17286r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17286r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17286r=globals




Bug #16698 Updated: phpinfo() hangs

2002-05-17 Thread spoon

 ID:   16698
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Apache2 related
 Operating System: Windows XP Pro
 PHP Version:  4.2.0
 New Comment:

Yes, i read about the bug.

Since my original posts, i have upgraded to the non-beta (stable) PHP
4.2 and using the expirimental modules. No problems since.


Previous Comments:


[2002-05-17 03:34:44] [EMAIL PROTECTED]

I'm having trouble reproducing this problem on Linux, with either the
threaded or non-threaded MPMs.  (Yes, I know you said you saw it on
WinXP.)  Can you generate a backtrace on this somehow?  Interrupt the
httpd task that's running out of control with MSVC's debugger and find
out what it's up to?  (Sorry I can't be much more specific on this, I
don't know much about MSVC.)  I assume you read 
http://www.apache.org/dist/httpd/binaries/win32/#xpbug , right?

Thanks,
Cliff



[2002-04-21 18:56:59] [EMAIL PROTECTED]

From reading other bugs about corrupted output on XP systems, i tried
one of the WORK AROUNDS that do not fix the problem, but hide it (which
is good enough for me untill an actual fix is found).

I did the suggested (and disputed by php.net) method of having the
content gzipped. It does HIDE the problem (in their bug and in mine).
But like php.net said, it is not recomended.

phpinfo() does not hang, and i have no corrupted output, with gzip on.



[2002-04-19 10:28:23] [EMAIL PROTECTED]

a php file containing nothing but:

?

phpinfo();

?

loads about halfway, then stops. the server running php+apache then
goes into 5 second freezes and 5 second 100% usage peaks. These
happens consistantly and hoses the system untill all other processes
cant function.

The error logs show nothing, and the event viewer (windows)shows
nothing. It also happens when i use:

show_source(php_script.php);

on a fairly small script.

I am using the Apache2filter test module.

I can't currently show you an example of this becuase: my server just
went down, and im at work (it's at home) and it would crash if i showed
you! When i get home i will recreate the bug a 3rd time to make sure im
not crazy.




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




Bug #16888 Updated: domXML causes Segfault, when you create to many Nodes

2002-05-17 Thread chregu

 ID:   16888
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Critical
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  4.2.0
 New Comment:

Ok, i did some tests on linux and indeed

There is a big f**king memory hole in domxml with
append_child/append_sibling :( even with Josephs patch.

I will investigate further today...




Previous Comments:


[2002-05-16 19:17:32] [EMAIL PROTECTED]

Oh, and I've tested it to work with 70,000 elements...



[2002-05-16 19:04:25] [EMAIL PROTECTED]

I seem to have found the problem.  Nodes are being freed twice: once in
a call to php_free_xml_node, and once in a call to node_wrapper_dtor. 
I've made two changes, one i've replaced the free code in
php_free_xml_node with a call to the static inline function
node_wrapper_dtor, and then call dom_object_set_data to clear the data
(a check should be put here to make sure that the refcount is 0 before
doing this, but I don't have time right now).  I'll post the patch to
the php-dev list so that people can look it over, and make sure that it
doesn't introduce any memory leaks.  I'll mark the bug fixed when I
commit my change.



[2002-05-16 15:59:08] [EMAIL PROTECTED]

Ahh,  Now I'm understanding the original poster.  I never got the 404
page.  Must have been a browser specific issue.  The error occurs in
the cleanup routines on both iis and apache.  The stack trace is as
follows:

_zval_ptr_dtor(_zval_struct * * 0x00e2f568, char * 0x10023020 `string',
unsigned int 0x01f8) line 272 + 5 bytes
node_wrapper_dtor(_xmlNode * 0x005cb9c8) line 504 + 26 bytes
node_list_wrapper_dtor(_xmlNode * 0x005cb9c8) line 531 + 9 bytes
node_list_wrapper_dtor(_xmlNode * 0x005c3c18) line 521 + 12 bytes
php_free_xml_doc(_zend_rsrc_list_entry * 0x00e38e18, void * * *
0x00afe7a8) line 563 + 12 bytes
list_entry_destructor(void * 0x00e38e18) line 177 + 16 bytes
zend_hash_apply_deleter(_hashtable * 0x00b2cac4, bucket * 0x00e38db8)
line 596 + 15 bytes
zend_hash_graceful_reverse_destroy(_hashtable * 0x00b2cac4) line 662 +
13 bytes
zend_destroy_rsrc_list(_hashtable * 0x00b2cac4, void * * * 0x00afe7a8)
line 233 + 9 bytes
shutdown_executor(void * * * 0x00afe7a8) line 196 + 30 bytes
zend_deactivate(void * * * 0x00afe7a8) line 596 + 9 bytes
php_request_shutdown(void * 0x) line 787 + 9 bytes
apache_php_module_main(request_rec * 0x00afc798, int 0x, void *
* * 0x00afe7a8) line 96 + 8 bytes
send_php(request_rec * 0x00afc798, int 0x, char * 0x00afd248)
line 575 + 17 bytes
send_parsed_php(request_rec * 0x00afc798) line 590 + 13 bytes
ap_invoke_handler(request_rec * 0x00afc798) line 517 + 10 bytes
process_request_internal(request_rec * 0x00afc798) line 1308 + 9 bytes
ap_process_request(request_rec * 0x00afc798) line 1324 + 9 bytes
child_sub_main(int 0x) line 5881




[2002-05-16 14:05:41] [EMAIL PROTECTED]

The crash occurs weather you use append_sibling or append_child



[2002-05-16 13:29:39] [EMAIL PROTECTED]

To narrow down the problem. Does it also crash, when you don't use
append_sibling, but append_child in the for-loop?

chregu



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/16888

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




Bug #16583 Updated: php 4.2.0RC3 always crashes apache 2.0.35 server at start

2002-05-17 Thread sniper

 ID:   16583
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: PLD Linux
 PHP Version:  4.2.0RC4


Previous Comments:


[2002-04-21 18:46:24] [EMAIL PROTECTED]

This is the same bug as #16475.  I concur that the
problem appears to be some form of heap corruption... I
can easily reproduce the problem myself.  Further followup
will be done under bug #16475.  Thanks!



[2002-04-20 08:38:39] [EMAIL PROTECTED]

Building w/ optimizations off (CFLAGS=-g -Wall) won't
help either.



[2002-04-20 08:27:12] [EMAIL PROTECTED]

100% reproducible, crashes on loadmodule.

$ gcc -v
gcc version 2.95.3 20010315 (release)

$ uname -r
2.4.19-pre7-ac2

configured as
  ./configure \
  --prefix=/usr \
  --sysconfdir=/etc \
  --localstatedir=/var \
  --with-apxs2=/var/lib/httpd/bin/apxs \
  --with-zlib \
  --without-mysql \
  --with-pgsql=/var/lib/pgsql \
  i386-slackware-linux



[2002-04-19 12:11:07] [EMAIL PROTECTED]

%configure \
 --with-apxs2=%{_sbindir}/apxs` \
--with-config-file-path=%{_sysconfdir} \
--with-exec-dir=%{_bindir} \
--enable-bcmath=shared \
--enable-calendar=shared \
--enable-dba=shared \
--enable-exif=shared \
--enable-ftp=shared \
--enable-gd-native-ttf \
--enable-magic-quotes \
--enable-posix=shared \
--enable-session \
--enable-shared \
--enable-shmop=shared \
--enable-sysvsem=shared \
--enable-sysvshm=shared \
--enable-track-vars \
--enable-trans-sid \
--enable-safe-mode \
--enable-sockets=shared \
--enable-yp=shared \
--enable-ucd-snmp-hack \
--enable-xml=shared \
--with-expat-dir=/usr \
--with-bz2=shared \
--with-ctype=shared \
--with-curl=shared \
--without-db2 \
--with-db3 \
--with-dbase=shared \
--with-iconv=shared \
--with-dom=shared \
--with-dom-xslt=shared \
--with-filepro=shared \
--with-freetype-dir=shared \
--with-gettext=shared \
--with-gd=shared \
--with-gdbm \
--with-gmp=shared \
--with-hyperwave \
--with-imap=shared --with-imap-ssl \
--with-jpeg-dir=%{_includedir} \
--with-ldap=shared \
--with-mcrypt=shared \
--with-mysql=shared,%{_prefix} \
--with-mysql-sock=/var/lib/mysql/mysql.sock \
--with-mhash=shared \
--with-ming=shared \
 --without-mm \
--with-openssl \
--with-pear=%{peardir} \
--with-pcre-regex=shared \
--with-pdflib=shared \
--with-pgsql=shared,%{_prefix} \
--with-png-dir=%{_includedir} \
--without-recode=shared \
--with-regex=php \
--with-sablot=/usr/lib \
--with-snmp=shared \
--with-t1lib=shared \
--with-unixODBC=shared \
--with-zlib=shared \
--with-zlib-dir=shared \
--without-xmlrpc \
--disable-cli

whole spec file is here:
http://cvs.pld.org.pl/SPECS/php.spec?rev=1.120.2.17

src.rpm is here:
ftp://ftp.pld.org.pl/dists/nest/test/SRPMS/php-4.2.0RC4-1.src.rpm

while building I was using rpm --debug, so in such case
rpm sets CFLAGS=-g -O0

buildlog is here:
ftp://buildlogs.pld.org.pl/nest/i686/OK/_r_DEVEL_php.bz2
(the only difference between this buildlog and mine is that I was
compiling with CFLAGS=-g -O0)



[2002-04-19 12:08:16] [EMAIL PROTECTED]

%configure \
--with-apxs2=%{_sbindir}/apxs` \
%else
`[ $i = apxs ]  echo --with-apxs=%{_sbindir}/apxs` \
%endif  
--with-config-file-path=%{_sysconfdir} \
--with-exec-dir=%{_bindir} \
--%{!?debug:dis}%{?debug:en}able-debug \
--enable-bcmath=shared \
--enable-calendar=shared \
--enable-dba=shared \
--enable-exif=shared \
--enable-ftp=shared \
--enable-gd-native-ttf \
--enable-magic-quotes \
--enable-posix=shared \
--enable-session \
--enable-shared \
--enable-shmop=shared \
--enable-sysvsem=shared \
--enable-sysvshm=shared \
--enable-track-vars \
--enable-trans-sid \
--enable-safe-mode \
--enable-sockets=shared \
--enable-yp=shared \
--enable-ucd-snmp-hack \
--enable-xml=shared \
--with-expat-dir=/usr \

Bug #16104 Updated: Apache2 segfault on startup in TSRM/TSRM.c:310

2002-05-17 Thread sniper

 ID:   16104
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Linux
 PHP Version:  4.0CVS-2002-03-1


Previous Comments:


[2002-04-21 18:44:31] [EMAIL PROTECTED]

This is the same bug as #16475.  I'm marking this one as
duplicate... further followup will happen under #16475.
Thanks!



[2002-04-19 11:17:53] [EMAIL PROTECTED]

This was back on ~2.0.33.  I haven't had the heart to try it recently.



[2002-04-19 11:14:06] [EMAIL PROTECTED]

What version of Apache is this? Current CVS is known to
work with Apache 2.0.35 (GA) and the 4.2.0 branch of PHP
(in CVS). Please try again and report your success/failure
here.



[2002-03-15 15:23:44] [EMAIL PROTECTED]

./configure \
 --with-apxs2=/usr/local/apache2/bin/apxs \
 --enable-debug

I have current HEAD code for both httpd-2.0 and php42.  If I try to
start apache with the php module, it silently crashes on startup.  So I
pop it into gdb and here's what I get.

(gdb) r -X
Starting program: /src/cvs/httpd-2.0/httpd -X
[New Thread 1024 (LWP 9253)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 9253)]
0x4031dad5 in ts_resource_ex (id=1, th_id=0x0) at
/src/cvs/php4/TSRM/TSRM.c:310
310
TSRM_SAFE_RETURN_RSRC(thread_resources-storage, id,
thread_resources-count);

(gdb) l
305 TSRM_ERROR((TSRM_ERROR_LEVEL_INFO,
Fetching resource id %d for current thread %d, id, (long)
thread_resources-thread_id));
306 /* Read a specific resource from the
thread's resources.
307  * This is called outside of a mutex,
so have to be aware about external
308  * changes to the structure as we read
it.
309  */
310
TSRM_SAFE_RETURN_RSRC(thread_resources-storage, id,
thread_resources-count);
311 }
312 thread_id = tsrm_thread_id();
313 } else {
314 thread_id = *th_id; 

(gdb) bt
#0  0x4031dad5 in ts_resource_ex (id=1, th_id=0x0)
   at /src/cvs/php4/TSRM/TSRM.c:310
#1  0x40321bfd in php_module_startup (sf=0x4044eba0)
   at /src/cvs/php4/main/main.c:856
#2  0x403746f4 in php_apache_server_startup (pconf=0x81014c0,
plog=0x81395a0,
   ptemp=0x818ad58, s=0x818dfd8)
   at /src/cvs/php4/sapi/apache2filter/sapi_apache2.c:428
#3  0x0808e43f in ap_run_post_config (pconf=0x81014c0, plog=0x81395a0,
ptemp=0x818ad58, s=0x818dfd8) at config.c:127
#4  0x08092715 in main (argc=2, argv=0xb6e4) at main.c:603

(gdb) p *thread_resources
$2 = {storage = 0x50435245, count = 33, thread_id = 135231232, next =
0x2010} 

Anybody have helpful suggestions here? This is fully repeatable.





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




Bug #16793 Updated: setcookie() broken

2002-05-17 Thread sniper

 ID:   16793
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Linux 2.4
 PHP Version:  4.0CVS-2002-04-2
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2002-04-24 10:00:22] [EMAIL PROTECTED]

Hmm.. apparently a dup. of 16626.



[2002-04-24 09:18:09] [EMAIL PROTECTED]

Trying to set several cookies in a row using, say,

  $ts = time();
  setcookie(dsession, $ckey, $ts + 31536);
  setcookie(dlogin, $username, $ts + 31536);
  setcookie(dlang, $slang, $ts + 31536);

results in only the last cookie being actually sent
by Apache 2.0.35. This becomes obvious if one switches
the order of the setcookie() calls and traces the
HTTP communication with 'lynx -trace'.

Happy debugging. :)




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




Bug #17210 Updated: Apache 2 restart

2002-05-17 Thread sniper

 ID:   17210
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Linux 8.2
 PHP Version:  4.2.1


Previous Comments:


[2002-05-14 11:12:07] [EMAIL PROTECTED]

please don't open new bugreports. add comments to the existing one(s)
instead, thank you.



[2002-05-14 11:06:10] [EMAIL PROTECTED]

Bug #17113 continues in PHP 4.2.1

bin/apachectl restart

does not work, but give a segmentation error.

Jan P. Sorensen




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




Bug #16631 Updated: Only one (last?) cookie send to browser

2002-05-17 Thread sniper

 ID:   16631
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Linux 2.2.14
 PHP Version:  4.0CVS-2002-04-1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2002-04-17 15:04:52] [EMAIL PROTECTED]

Dupe of #16626



[2002-04-16 06:56:10] [EMAIL PROTECTED]

Test php script.

?php

  setcookie('abc', 'abc', time() + (60 * 60 * 24 * 365), '/');
  setcookie('xyz', 'xyz', time() + (60 * 60 * 24 * 365), '/');

  echo Hallo World \n\n;

?

Respons with Apache 2.0.35 / PHP 4.2.0 RC4

HTTP/1.1 200 OK
Date: Tue, 16 Apr 2002 09:45:03 GMT
Server: Apache/2.0.35 (Unix) PHP/4.2.0RC4
Accept-Ranges: bytes
X-Powered-By: PHP/4.2.0RC4
Set-Cookie: xyz=xyz; expires=Wed, 16-Apr-03 09:45:04 GMT; path=/
Connection: close
Content-Type: text/html
X-Pad: avoid browser bug

Respons with Apache 1.3.22 en PHP 4.0.6

HTTP/1.1 200 OK
Date: Tue, 16 Apr 2002 09:49:55 GMT
Server: Apache/1.3.22 (Unix) PHP/4.0.6 mod_ssl/2.8.5
OpenSSL/0.9.6b
X-Powered-By: PHP/4.0.6
Set-Cookie: abc=abc; expires=Wed, 16-Apr-03 09:49:56 GMT; path=/
Set-Cookie: xyz=xyz; expires=Wed, 16-Apr-03 09:49:56 GMT; path=/
Connection: close
Content-Type: text/html

Greetings, Herbert




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




Bug #15684 Updated: Undefined symbol pthread_getspecific

2002-05-17 Thread sniper

 ID:   15684
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: FREEBSD 4.4-STABLE
 PHP Version:  4.1.1
 New Comment:

this was said to be fixed already in CVS.



Previous Comments:


[2002-03-15 09:57:02] [EMAIL PROTECTED]

Duplicate of #14594



[2002-03-15 04:05:33] [EMAIL PROTECTED]

this is cross referenced with 14594



[2002-03-09 13:49:36] [EMAIL PROTECTED]

Could you please try the latest CVS snapshot?




[2002-02-23 05:00:30] [EMAIL PROTECTED]

sorry, just checked the version of php, and it's actually PHP/4.2.0
from snaps.php.net :P



[2002-02-23 04:53:26] [EMAIL PROTECTED]

Configured php4.1.1 (latest from snaps.php.net as of last night)  with
options --with-mysql --with-apxs2=/path/to/my/apxs .  Configured, built
and installed , but when running apachectl configtest / restart , I get
this error.

bash-2.05# apachectl configtest
Syntax error on line 215 of /usr/local/apache2/conf/httpd.conf:
Cannot load /usr/local/apache2/modules/libphp4.so into server:
/usr/local/apache2/modules/libphp4.so: Undefined symbol
pthread_getspecific

However, I have rebuilt this after installing gnu portable threads from
ports, and using the configure line as follows

bash-2.05# ./configure --with-tsrm-pth --with-mysql
--with-apxs2=/usr/local/apache2/bin/apxs

this builds and installs afterwards.

Is this a bug in freeBSD threads , or a bug in php ?

Thanks :)






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




Bug #17256 Updated: httpd won't start , pth_mutex_release is undefined

2002-05-17 Thread sniper

 ID:   17256
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Duplicate
 Bug Type: Apache2 related
 Operating System: FreeBSD 4.5
 PHP Version:  4.2.1
 New Comment:

dup of #17255


Previous Comments:


[2002-05-15 13:17:14] [EMAIL PROTECTED]

Please do not submit the same bug more than once. There is a bug report
in the system with the same, or nearly the same contect. Please search
for
similar bugs before submitting a report.

Thank you for your interest in PHP.



[2002-05-15 13:10:22] [EMAIL PROTECTED]

hi and thanks for reading , 
i am using a freebsd 4.5 on an i386 , running php 4.2.1 , apache 2.0.36
,pth 1.4.1(as requested from php).
When i try to start httpd i get the following error message

Cannot load /usr/share/apache2/modules/libphp4.so into server:
/usr/share/apache2/modules/libphp4.so :Undefined symbol
pth_mutex_release

 i found out that pth_mutex_release is a synchronization function
...(?!?)
anybody has any idea?
thanks again
DsP





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




Bug #16852 Updated: Apache2 not compatible with php_admin_value, php_value, php_flag ....

2002-05-17 Thread sniper

 ID:   16852
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Any
 PHP Version:  4.0CVS-2002-04-26
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2002-04-26 09:13:16] [EMAIL PROTECTED]

This was submited some more times already... duplicate.

Derick



[2002-04-26 09:04:43] [EMAIL PROTECTED]

I'm running Apache 2.0.35 / PHP 4.2.0 under win32 (php as a module of
Apache) and I can use php_admin,value, etc...

I'm also running Apache 2.0.35 / PHP4.3.0-dev (Auto-updated at Midnight
GMT+0200) and here too I can't use php_admin_value etc...

I have friends with also PHP4.2.0 and Apache2 and they can't use
php_admin_value .

It seems to be a bug or something that isn't already done in the
Apache2 module of php.

Apache2's answer is :
php_admin_value not allowed here.






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




Bug #16986 Updated: semaphore autorelease can be a bug....

2002-05-17 Thread wez

 ID:   16986
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Semaphore related
 Operating System: Linux 2.4.18
 PHP Version:  4.1.2
 New Comment:

The new proto for sem_get is:
proto int sem_get(int key [, int max_acquire [, int perm [, int
auto_release]])

auto_release defaults to true so original behaviour is preserved; you
may specify false to override.


Previous Comments:


[2002-05-07 10:58:07] [EMAIL PROTECTED]

Some people write me for explanations.

ok I'll be more clear I hope:

READER:
p(mutex);
readcount++;
if (readcount is 1) then p(db);
v(mutex);
CRITICAL REGION where we read
p(mutex);
readcount--;
if (readcount  is 0) then v(db);
v(mutex);
WRITER:
p(db);
CRITICAL REGION where we write
v(db);

this is the simplest r/w problem, ok ?!?

let we analize it now.
we have to acquire some mutex to protect owr access to variables
readcount ok
??
This is possible in PHP! .. ok !

now, I'm the 1st reader .. I acquire sem DB becouse readcount is equal
to 1,
I release mutex and begin to READ

NOW IT IS possible that an other reader arrive and it is faster than
me; it
DON'T  acquire DB becouse readcont is now 2, it READS and DOESN'T HAVE
to
release sem DB becouse readcount IS NOT 1 (reader 1  is still reading
!!)...

PHP AUTORELEASE DB ... damn !!!



[2002-05-06 10:44:30] [EMAIL PROTECTED]

Hi, I'm the coordinator of Italian Linux Portal and just last saturday
(04/05/2002 in european date) I have talked about PHP in a Linux Event.
I think that the rigth position is the position of AlberT: If a
script die and it has the semaphore is corret that another scripts
can get that semaphore.

my 0,02euro



[2002-05-06 10:23:00] [EMAIL PROTECTED]

It cause deadlock, but only on the script... if you test your script
and have a deadlock, you fix it and release the sem you forgot.

I think the auto release may be a good DEFAULT, but it is important to
be able to modify this behaviour.
If you want to fulfill any classical IPC problem (see Tanenbuam!)
You have to be able to acquire a sem, and not to realease it.

Here you ca nfind an explanation of the problems one can have and that
auto release make impossible to solve:

 
http://joda.cis.temple.edu/~ingargio/old/cis307f95/readings/readwriters.html



[2002-05-03 06:47:10] [EMAIL PROTECTED]

But a process that acquires a semaphore and then exits will
case deadlocks, because no one else can acquire the semaphore??
Can you give a good example of where leaving the semaphore acquired is
actually useful?



[2002-05-03 05:37:33] [EMAIL PROTECTED]

sem_acquire() function has this behavior:

After processing a request, any semaphores acquired by the process but
not explicitly released will be released automatically and a warning
will be generated. 

This is not a great thing, infact in this way the readers/writers
classical IPC problem, with writers precedence is impossible to
implement !!!

I think an option to disable autorelease is usefull.

(I sent a feature/change request, but I had no feadback :-( )





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




Bug #17274 Updated: sem_remove gets SIGSEGV for not initializing the semun structure.

2002-05-17 Thread wez

 ID:   17274
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Semaphore related
 Operating System: Linux 2.2.19
 PHP Version:  4.2.1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2002-05-16 14:01:08] [EMAIL PROTECTED]

Hi! PHP 4.2.1 gets a SIGSEGV in sem_remove().

The code in ext/sysvsem/sysvsem.c seems to forget the allocation of the
buf member of the semun struct when it calls to semctl().

I solved it adding:
   struct semid_ds semidbuf;
to the declaration of local variables, and:
   un.buf = semidbuf;
before each call to semctl();

I configured PHP using:

configure --enable-sysvshm --enable-sysvsem
--with-curl=/usr/local/lib/libcurl.a --enable-pcntl

This is the gdb stack trace:

(gdb) where
#0  0x402864e2 in __new_semctl (semid=770, semnum=0, cmd=2)
at ../sysdeps/i386/i486/bits/string.h:315
#1  0x80be3a3 in zif_sem_remove (ht=1, return_value=0x81a13cc,
this_ptr=0x0, 
return_value_used=0) at sysvsem.c:406
#2  0x80fe6cf in execute (op_array=0x81946b8) at ./zend_execute.c:1598
#3  0x80fe889 in execute (op_array=0x8186c14) at ./zend_execute.c:1638
#4  0x80e4289 in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at zend.c:810
#5  0x8062879 in php_execute_script (primary_file=0xbbd0) at
main.c:1381
#6  0x8060850 in main (argc=5, argv=0xbc74) at cgi_main.c:778
#7  0x401c2b65 in __libc_start_main (main=0x8060054 main, argc=5, 
ubp_av=0xbc74, init=0x805ec7c _init, fini=0x81037bc _fini,

rtld_fini=0x4000df24 _dl_fini, stack_end=0xbc6c)
at ../sysdeps/generic/libc-start.c:111





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




Bug #17260 Updated: Dynamic Library support not available

2002-05-17 Thread sniper

 ID:   17260
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: Linux
 PHP Version:  4.2.1
 New Comment:

What does config.log have about checking dlopen ?

--Jani



Previous Comments:


[2002-05-15 18:05:41] [EMAIL PROTECTED]

The message Dynamic Library support not available appears in
phpinfo.

My configuration :
Mandrake 8.1 Linux 2.4.8-34.1mdk 
Apache/2.0.36 (Unix) DAV/2 PHP/4.2.1 
autoconf 2.53
automake 1.6.1
libtool 1.4.2
gcc 2.96

To compile PHP I use :
'./configure' '--enable-bcmath=shared' '--enable-calendar=shared'
'--enable-dba=shared' '--enable-dio=shared' '--enable-ftp=shared'
'--enable-gd-native-ttf=shared' '--enable-mbstring=shared'
'--enable-mbregex=shared' '--enable-sockets=shared'
'--enable-tockenizer=shared' '--enable-xml=shared'
'--enable-xslt=shared' '--with-apxs2=/usr/local/apache2/bin/apxs'
'--with-pear' '--with-openssl=shared' '--with-zlib=shared'
'--with-bz2=shared' '--with-dom=shared' '--with-dom-xslt=shared'
'--with-gd=shared' '--with-jpeg-dir=/usr' '--with-png-dir=/usr'
'--with-freetype-dir=/usr' '--with-ttf=/usr' '--with-gettext=shared'
'--with-java=/usr/local/java/j2sdk1.4.0' '--with-mysql=shared,/usr'
'--with-xslt-sablot=shared,/usr' '--with-iconv=shared,/usr'




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




Bug #17268 Updated: unset() hangs in infinite loop with Apache 1.3.24

2002-05-17 Thread mrobinso

 ID:   17268
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Linux 2.4
 PHP Version:  4.2.1
 New Comment:

Can you provide more details on your setup please?

I'm not able to reproduce this on my 2.4 box running
Apache-1.3.24. In fact, I used unset in almost every
conceivable way without a problem.


Previous Comments:


[2002-05-16 06:14:42] [EMAIL PROTECTED]

No special script is required; even simple unset() calls fail:


?php

$test = test;

print start;
unset($test);   // hangs and finally fails due to timeout in this line

?



[2002-05-16 05:34:12] [EMAIL PROTECTED]

Please provide a short reproducing script.

Derick



[2002-05-16 05:20:59] [EMAIL PROTECTED]

My PHP 4.2.1 with Apache 1.3.24 has the following problem:

unset() hangs in most cases in an infinite loop. It's independent from
the type of the variable, or if the variable does exist at all.

I experienced this problem only with the Apache-compiled-in version;
the same PHP version as standalone CGI with the same compile options
and php.ini doesn't have this problem.

The apache process executing a script which came to an unset() call
uses 90% of the CPU time until it gets stopped by the maximum
execution time limit.

register_globals is set to On.





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




Bug #17282 Updated: Identical float values are not identical when compared

2002-05-17 Thread rasmus

 ID:   17282
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.4-STABLE
 PHP Version:  4.2.1
 New Comment:

So change your precision setting in your php.ini file if you want the
higher display precision.


Previous Comments:


[2002-05-17 04:11:51] [EMAIL PROTECTED]

You're right, floats aren't precise, but neither is your output. I
don't know if it is rounded or something odd, but if you say it
operates the same as in C, I challenge you to test adding 20.99 and
20.97 in C and compare it to 41.96.

You will find that they are not the same BUT c does the correct
response by outputting it's float value of 41.95 instead of 41.96

In your case, the comparison should be on the value that is used for
display and etc.



[2002-05-17 03:25:19] [EMAIL PROTECTED]

sorry, didn't see your earlier update.

However, I'd just like to comment that it is rediculous that a feature
exists that is known to be false.



[2002-05-17 03:22:55] [EMAIL PROTECTED]

Ah, but the source is very interesting.

?
$b = 41.00;
$b2 = 00.96;

$c = array(41.96,41.00,00.96,0.00,41.96);
for($i=1;$i3;$i++)
 $c[3]+=$c[$i];

echo p;
var_dump($c[3] != $c[0]);

echo p;
var_dump($c[4] != $c[0]);

echo p;
$b2 = $b + $b2;
var_dump($c[0] != $b2);

echo p;
var_dump($c[3] != $b2);
?

OUTPUT:

bool(false) 

bool(false) 

bool(false) 

bool(false) 

Why is it those 2 numbers only?



[2002-05-17 02:41:23] [EMAIL PROTECTED]

Actually this is documented:
http://www.php.net/manual/en/language.types.float.php

 I am well aware that there can be errors due to loss of precision,
but
 in that case, the number should not appear to be _exactly the same_.
 There should be some way to tell that they are different.

You can tell they are different by comparing them, which obviously
almost always fails, but i fyou do this:

if (41.96 == 41.96)

it will return true ofcourse.

There was some discussion on this topic before, and the consensus of
the list was not to change anything related to this.

regards,
Derick



[2002-05-17 02:36:19] [EMAIL PROTECTED]

That does not seem right.  The numbers appear to be exactly the same. 
Even if they can't be compared as floats, comparing untyped should
work, because they look exactly the same (when var_dump'd and
printed).

Even if this is in fact bogus, it needs to be documented.  

I am well aware that there can be errors due to loss of precision, but
in that case, the number should not appear to be _exactly the same_. 
There should be some way to tell that they are different.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/17282

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




Bug #17287: safe mode is not full safe.

2002-05-17 Thread raven

From: [EMAIL PROTECTED]
Operating system: Linux + apache 1.3
PHP version:  4.2.0
PHP Bug Type: *General Issues
Bug description:  safe mode is not full safe.

On set_time_limit documentation web page stands:
 set_time_limit() has no effect when PHP is running in safe mode. There is
no workaround other than turning off safe mode or changing the time limit
in the configuration file. 

which is false, becouse You may do: ini_set(max_execution_time, any
value) and it success even in safe_mode.
I consider it as a bug.
I guess this will work for memory_limit also.

Raven

-- 
Edit bug report at http://bugs.php.net/?id=17287edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17287r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17287r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17287r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17287r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17287r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17287r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17287r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17287r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17287r=globals




Bug #17288: ord returns wrong ascii values

2002-05-17 Thread tf

From: [EMAIL PROTECTED]
Operating system: linux
PHP version:  4.1.2
PHP Bug Type: *General Issues
Bug description:  ord returns wrong ascii values

ascii values for \b... \a (and some more) are missing.
they returns only 92.

e.g. value for \b should be 8...
-- 
Edit bug report at http://bugs.php.net/?id=17288edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17288r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17288r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17288r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17288r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17288r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17288r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17288r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17288r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17288r=globals




Bug #17290: Cannot use [] for reading

2002-05-17 Thread mellow

From: [EMAIL PROTECTED]
Operating system: Linux
PHP version:  4.1.2
PHP Bug Type: Arrays related
Bug description:  Cannot use [] for reading

I've build an array using the following in a function :

-
$this-get_data(array(,,and D.XiParentId= 'gwak_root_element' ORDER
BY D.vcOrder));
$arrCategory = $this-return_array();
for($i = 0 ; $i  sizeof($arrCategory) ; $i++) {
$this-get_data(array(,,and D.XiParentId = ' .
$arrCategory[$i][XiDataId] . ' ORDER BY D.vcOrder));
$arrItem[$arrCategory[$i][vcItemId]] =
$this-return_array();
}
return $arrItem;
-

This constructs an array with values like :
$arrItem[project_priority][0] = array(...)
$arrItem[project_priority][1] = array(...)
etc...

Later I tried to do the following to the returned $arrItem :
-
$arrItem[project_severity][] = array(XiDataId = gwak_get_all,
vcText = All);
-

This gives the error :
-
Fatal error: Cannot use [] for reading in
/home/plb/public_html/gwak/module/project/include/Task.class.php on line
160
-

Funny because doing the following :
-
$arrThis[here][] = array(XiDataId = asdasdas, vcText =
324234234);
$arrThis[here][] = array(XiDataId = asdasdas, vcText =
324234234);
$arrThis[here][] = array(tr = ert);
$arrThis[where][] = array(er = ert);
$arrThis[where][] = array(we = ert);
$arrThis[where][] = array(tr = ert);

-
gives no error at all, eventhough $arrThis and $arrItem have exactly the
same format. Do you guys have an idea what is going on here?

The only thing i can see could cause the problem is that $arrItem is built
using arrays within arrays:
$arrItem[$arrCategory[$i][vcItemId]] = array(...);
Can this be the cause or...

In advance thx...

-- 
Edit bug report at http://bugs.php.net/?id=17290edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17290r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17290r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17290r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17290r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17290r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17290r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17290r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17290r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17290r=globals




Bug #16888 Updated: domXML causes Segfault, when you create to many Nodes

2002-05-17 Thread chregu

 ID:   16888
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Critical
+Status:   Analyzed
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  4.2.0
 New Comment:

Other people sit at the lake and enjoy the stupid hot weather here, i
hunt memory leaks... what a pleasure... But i found it. Nodes which had
no parents were not freed. i have a fix, but it's not perfect yet.
expect a patch soon.


Previous Comments:


[2002-05-17 07:44:01] [EMAIL PROTECTED]

Ok, i did some tests on linux and indeed

There is a big f**king memory hole in domxml with
append_child/append_sibling :( even with Josephs patch.

I will investigate further today...





[2002-05-16 19:17:32] [EMAIL PROTECTED]

Oh, and I've tested it to work with 70,000 elements...



[2002-05-16 19:04:25] [EMAIL PROTECTED]

I seem to have found the problem.  Nodes are being freed twice: once in
a call to php_free_xml_node, and once in a call to node_wrapper_dtor. 
I've made two changes, one i've replaced the free code in
php_free_xml_node with a call to the static inline function
node_wrapper_dtor, and then call dom_object_set_data to clear the data
(a check should be put here to make sure that the refcount is 0 before
doing this, but I don't have time right now).  I'll post the patch to
the php-dev list so that people can look it over, and make sure that it
doesn't introduce any memory leaks.  I'll mark the bug fixed when I
commit my change.



[2002-05-16 15:59:08] [EMAIL PROTECTED]

Ahh,  Now I'm understanding the original poster.  I never got the 404
page.  Must have been a browser specific issue.  The error occurs in
the cleanup routines on both iis and apache.  The stack trace is as
follows:

_zval_ptr_dtor(_zval_struct * * 0x00e2f568, char * 0x10023020 `string',
unsigned int 0x01f8) line 272 + 5 bytes
node_wrapper_dtor(_xmlNode * 0x005cb9c8) line 504 + 26 bytes
node_list_wrapper_dtor(_xmlNode * 0x005cb9c8) line 531 + 9 bytes
node_list_wrapper_dtor(_xmlNode * 0x005c3c18) line 521 + 12 bytes
php_free_xml_doc(_zend_rsrc_list_entry * 0x00e38e18, void * * *
0x00afe7a8) line 563 + 12 bytes
list_entry_destructor(void * 0x00e38e18) line 177 + 16 bytes
zend_hash_apply_deleter(_hashtable * 0x00b2cac4, bucket * 0x00e38db8)
line 596 + 15 bytes
zend_hash_graceful_reverse_destroy(_hashtable * 0x00b2cac4) line 662 +
13 bytes
zend_destroy_rsrc_list(_hashtable * 0x00b2cac4, void * * * 0x00afe7a8)
line 233 + 9 bytes
shutdown_executor(void * * * 0x00afe7a8) line 196 + 30 bytes
zend_deactivate(void * * * 0x00afe7a8) line 596 + 9 bytes
php_request_shutdown(void * 0x) line 787 + 9 bytes
apache_php_module_main(request_rec * 0x00afc798, int 0x, void *
* * 0x00afe7a8) line 96 + 8 bytes
send_php(request_rec * 0x00afc798, int 0x, char * 0x00afd248)
line 575 + 17 bytes
send_parsed_php(request_rec * 0x00afc798) line 590 + 13 bytes
ap_invoke_handler(request_rec * 0x00afc798) line 517 + 10 bytes
process_request_internal(request_rec * 0x00afc798) line 1308 + 9 bytes
ap_process_request(request_rec * 0x00afc798) line 1324 + 9 bytes
child_sub_main(int 0x) line 5881




[2002-05-16 14:05:41] [EMAIL PROTECTED]

The crash occurs weather you use append_sibling or append_child



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/16888

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




Bug #17291: mssql_query does not update get_last_message

2002-05-17 Thread mgruetzner

From: [EMAIL PROTECTED]
Operating system: Linux
PHP version:  4.1.2
PHP Bug Type: Sybase (dblib) related
Bug description:  mssql_query does not update get_last_message

If you make the following calls in PHP 4.1.2 on Linux using freetds 0.53 to
connect to a MS SQL Server 7 database:

mssql_query (mystoredproc);
$msg = mssql_get_last_message ();
print $msg;

where mystoredproc is a stored procedure that returns N rows of data and
calls the SQL function below to send a warning message:

raiserror ('QueryLimit',9,1)

you would expect the value of $msg to be QueryLimit after the call to
mssql_query.  In fact, this is how it works on Windows but not on Linux
using freetds.  I have debugged this issue on both the freetds and php
software and found the following.  On Freetds, the message number that
gets returned from SQL is 5 which when stored as a 16-bit signed
integer is a negative value in the freetds code, so the freetds code
ignores the message.  I modified the freetds code to NOT ignore negative
message numbers but to go ahead and pass those messages on to the
appropriate callback function in PHP.  That helped matters, but there was
still an issue in the php code in the sybase_query function in
php_sybase_db.c.  Basically, what is happening is that in the case
described above, you receive 2 sets of database results as a result of the
query, but the sybase_query function is only reading the first set of
results.  To remedy the problem, I modified the sybase_query function to
save the results of the first call to dbresults().  Then, after reading
all the rows of data from the first set of results, I checked the result
of the first call to dbresults.  If it is not set to NO_MORE_RESULTS, I
call dbresults again to read the second set of results, which in this
case, is the warning message.  By doing so, this causes the freetds
software to recognize the message and callback PHP with the message.  I
have tested these fixes on Linux and they seem to work find I can email
the source code for the fix if you are interested


-- 
Edit bug report at http://bugs.php.net/?id=17291edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17291r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17291r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17291r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17291r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17291r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17291r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17291r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17291r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17291r=globals




Bug #17289: missing word in german translation

2002-05-17 Thread c . loeffler

From: [EMAIL PROTECTED]
Operating system: N.A.
PHP version:  4.2.1
PHP Bug Type: Documentation problem
Bug description:  missing word in german translation

in http://de.php.net/manual/de/class.variant.php 
(german translation of the manual):

VARIANT

(unknown)
VARIANT -- VARIANT Klasse
Synopsis

$vVar = new VARIANT($var)

Beschreibung

Ein einfacher Container, um Variablen VARIANT Strukturen zu verpacken. 

There is missing the word 'in' between 'Variablen' and 'VARIANT'. The
correct sentence must be something like:

Ein einfacher Container, um Variablen in VARIANT Strukturen zu verpacken.



-- 
Edit bug report at http://bugs.php.net/?id=17289edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17289r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17289r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17289r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17289r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17289r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17289r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17289r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17289r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17289r=globals




Bug #11616 Updated: Cc: Bcc: not being picked up from header

2002-05-17 Thread mfischer

 ID:   11616
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Assigned
 Bug Type: Mail related
 Operating System: Win 2K Server
 PHP Version:  4.0.5
 Assigned To:  hholzgra
 New Comment:

Bcc support has been added. RFC style mail addresses are still not
done.


Previous Comments:


[2001-06-23 00:47:10] [EMAIL PROTECTED]

I have one more behavior to add.  The mail() function only can gather
To: addresses if they are in this format:

mail([EMAIL PROTECTED], [EMAIL PROTECTED], etc)

It should be able to read this RFC format as well:

mail(Gary [EMAIL PROTECTED], Beth [EMAIL PROTECTED], etc)

There are a lot of changes to be made. If I find the time I will try
some fixes myself.



[2001-06-22 18:26:24] [EMAIL PROTECTED]

windwos mail code needs a rewrite



[2001-06-22 10:21:44] [EMAIL PROTECTED]

I am running PHP as CGI on IIS 5.0 with service pack 2.  

This report verifies that bug #11349 is a definate problem.
/win32/sendmail.c has the following code (starting at line 253):

/* Send mail to all Cc rcpt's */
efree(tempMailTo);
if (headers  (pos1 = strstr(headers, Cc:))) {
pos2 = strstr(pos1, \r\n);
tempMailTo = estrndup(pos1, pos2-pos1);

token = strtok(tempMailTo, ,);
while(token != NULL)
{
sprintf(Buffer, RCPT TO:%s\r\n, token);
if ((res = Post(Buffer)) != SUCCESS)
return (res);
if ((res = Ack()) != SUCCESS)
return (res);
token = strtok(NULL, ,);
}
efree(tempMailTo);
}

The above code can only grab an email address that looks like this: 

Cc: [EMAIL PROTECTED]

When I place it in this format I receive a Warning:  Server Error
message from the mail() function.

sendmail.c cannot find a proper RFC 822 mail header like:

Cc: Jack Smith [EMAIL PROTECTED]

When I place this in the mail headers nothing happens.

Also, there is no code at all that even looks for a Bcc address in the
sendmail.c code.  This is a massive problem.

In order for the mail() function to be /usr/sbin/sendmail compliant it
must be able to find and parse Cc: and Bcc: in each of the above
formats. It must also remove the Bcc's from the header so that
recieving mail clients cannot see them, just as sendmail does.

Brent




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




Bug #13519 Updated: Filename time.h conflict in VS.NET

2002-05-17 Thread mfischer

 ID:   13519
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Suspended
+Status:   Feedback
 Bug Type: Compile Failure
 Operating System: Windows 2000 SP2
 PHP Version:  4.0.6
 New Comment:

I think people already reported that it works with VS.NET, can you give
it a try with latest sources?


Previous Comments:


[2001-10-02 15:09:24] [EMAIL PROTECTED]

again vs.net is not yet supported.
actually php's time.h includes the system time.h so i don't know what
the change is going to resolve...
maybe something's messed with your include paths.



[2001-10-02 14:52:32] [EMAIL PROTECTED]

Whoops!  There are a _lot_ more than just those two files that require
time.h to be changed to  _time.h.  Lousy non-regex search :)



[2001-10-02 14:46:27] [EMAIL PROTECTED]

I _believe_ this issue only applies to VS.NET, but have not tested it
in earlier versions.

Using Visual Studio 7.0 build 9254 (VS.NET Beta 2), the build of
time.c and sendmail.c fail because header time.h fails to be
included.  Checking the sources, it is absolutely impossible for the
#include time.h statement not to be compiled, but the statement
appeared to be ignored anyway.

When the filename of time.h (in /win32) is changed to _time.h and
the approriate #include lines in time.c and sendmail.c are
modified, compilation succeeds normally.  A little testing showed that
VS.NET was including time.h (part of php4) instead of time.h (part
of msvcrt.dll).  Once the filename conflict was resolved, the correct
file was included.




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




Bug #17216 Updated: DOM XML uses non-DOM compliant calls

2002-05-17 Thread hubweb

 ID:   17216
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: All
 PHP Version:  4.2.1
 New Comment:

On s'en sacre-tu rien qu'un peu ??? Tant que ça marche batard, c'est
parfait ! Non ???


Previous Comments:


[2002-05-14 16:30:33] [EMAIL PROTECTED]

I could not help but notice that all DOM XML calls use an
underscore-based convention:

i.e.
$mynode-append_child($achild);

I am no language lawyer but if you read the DOM Core documentation
(http://www.w3.org/TR/DOM-Level-3-Core/core.html) it suggests a
case-based (no underscore) convention:

i.e.
$mynode-appendChild($achild);

Also, every DOM compliant library that I've looked at uses this same
convention.  Will the case-based convention be used in PHP 4.3.0?  If
not then it should be considered as it seems to be a violation of the
DOM.

Warm regards,

Brent




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




Bug #14407 Updated: Win32 SendMail function doesn't use From: in SMTP MAIL FROM command

2002-05-17 Thread mfischer

 ID:   14407
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Closed
 Bug Type: Mail related
 Operating System: Windows 2000
 PHP Version:  4.0CVS-2001-12-10
 New Comment:

Fixed in CVS.


Previous Comments:


[2002-05-14 10:02:19] [EMAIL PROTECTED]

Can you post a unified diff against latest CVS HEAD to
[EMAIL PROTECTED] please ?



[2001-12-10 12:27:12] [EMAIL PROTECTED]

The SendMail function that is used for Win32 platforms doesn't extract
the From: header address to use as for the SMTP MAIL FROM command. 
As a result any mail bounces go to the sendmail_from php.ini option
instead of to the sender.  This is handled correctly in the PostHeader
function (which doesn't add From: if it is already there), but not in
TSendMail.  The patch for win32/sendmail.c below allows TSendMail to
use the e-mail from address if it is available, and default to the
sendmail_from setting otherwise.

124,128c124,142
 
   if (INI_STR(sendmail_from)){
   RPath = estrdup(INI_STR(sendmail_from));
   } else {
   return 19;
---
 
   if (headers  strstr(headers, From:)) {
   char *pos;
   pos = strstr(headers, From:) + 5;
   while (pos  (*pos == ' '))
   pos++;
 
   if (pos  strlen(pos)) {
   RPath = estrdup(pos);
   RPath[strcspn(RPath, \r\n)] = '\x0';
   }
   }
   
   if (!RPath) {
   if (INI_STR(sendmail_from)) {
   RPath = estrdup(INI_STR(sendmail_from));
   } else {
   return 19;
   }




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




Bug #17222 Updated: header(Location: ...) doesn't work properly

2002-05-17 Thread hubweb

 ID:   17222
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Apache related
 Operating System: Windows2000 Pro (SP: RC3.51)
 PHP Version:  4.2.0
 New Comment:

What if you try :
Header(Location: http://www.yahoo.com\n;);
??


Previous Comments:


[2002-05-15 14:33:05] [EMAIL PROTECTED]

You're very likely to do something wrong. Please ask support on the
appropriate mailinglist.



[2002-05-15 07:41:43] [EMAIL PROTECTED]

Works just fine on my Apache 1.3.24 with PHP 4.2.0 as a module.

(Just copied/pasted the stuff)

/Leblanc



[2002-05-14 18:18:23] [EMAIL PROTECTED]

The script:

header(Location: http://www.yahoo.com/;);

This wouldn't work at all, and my Apache returns an empty result. With
a 500 status. Very weird.

I use Apache 1.3.24-Win32 (precompiled binary) and I use php as a
module.

The exact same script using PHP 4.1.2 works fine (no modification at
all to Apache configs or even php.ini!!)
I'm downloading 4.2.1 now and will update this (if possible) when I've
tried it...

enabled PHP extensions: gd  zlib




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




Bug #17230 Updated: Variables not hitting script!!!

2002-05-17 Thread hubweb

 ID:   17230
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: RH Linux 7.2
 PHP Version:  4.2.1
 New Comment:

Use $_GET[mod] instead of $mod.
If you request method is POST = $_POST[mod].


Previous Comments:


[2002-05-14 21:06:49] [EMAIL PROTECTED]

In PHP 4.2.0, the 'register_globals' setting default changed to
be off. See http://www.php.net/release_4_2_0.php for more info.
We are sorry about the inconvenience, but this change was a necessary
part of our efforts to make PHP scripting more secure and portable.



[2002-05-14 21:05:21] [EMAIL PROTECTED]

BIG PROBLEM!!! I have tried this on both 4.2.0 and 4.2.1 on both IIS
5.1 and Apache (Linux 7.3):

if i define a variable using a url, example:

module.php?mod=hello

the variable $mod DOES NOT get set in a VERY simple script:

?

echo $mod;

?

and give me an Undefined Variable Error




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




Bug #16888 Updated: domXML causes Segfault, when you create to many Nodes

2002-05-17 Thread chregu

 ID:   16888
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Analyzed
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  4.2.0
 New Comment:

My patch is available at
http://trash.chregu.tv/domxml-memleak.diff
(for CVS-HEAD, but should be applyable to PHP_4_2_0 branch as well)

The big memory hole is certainly fixed with that, don't know about
windows and the little memleaks...

Would be great, if someone could test it. 


Previous Comments:


[2002-05-17 11:44:09] [EMAIL PROTECTED]

Other people sit at the lake and enjoy the stupid hot weather here, i
hunt memory leaks... what a pleasure... But i found it. Nodes which had
no parents were not freed. i have a fix, but it's not perfect yet.
expect a patch soon.



[2002-05-17 07:44:01] [EMAIL PROTECTED]

Ok, i did some tests on linux and indeed

There is a big f**king memory hole in domxml with
append_child/append_sibling :( even with Josephs patch.

I will investigate further today...





[2002-05-16 19:17:32] [EMAIL PROTECTED]

Oh, and I've tested it to work with 70,000 elements...



[2002-05-16 19:04:25] [EMAIL PROTECTED]

I seem to have found the problem.  Nodes are being freed twice: once in
a call to php_free_xml_node, and once in a call to node_wrapper_dtor. 
I've made two changes, one i've replaced the free code in
php_free_xml_node with a call to the static inline function
node_wrapper_dtor, and then call dom_object_set_data to clear the data
(a check should be put here to make sure that the refcount is 0 before
doing this, but I don't have time right now).  I'll post the patch to
the php-dev list so that people can look it over, and make sure that it
doesn't introduce any memory leaks.  I'll mark the bug fixed when I
commit my change.



[2002-05-16 15:59:08] [EMAIL PROTECTED]

Ahh,  Now I'm understanding the original poster.  I never got the 404
page.  Must have been a browser specific issue.  The error occurs in
the cleanup routines on both iis and apache.  The stack trace is as
follows:

_zval_ptr_dtor(_zval_struct * * 0x00e2f568, char * 0x10023020 `string',
unsigned int 0x01f8) line 272 + 5 bytes
node_wrapper_dtor(_xmlNode * 0x005cb9c8) line 504 + 26 bytes
node_list_wrapper_dtor(_xmlNode * 0x005cb9c8) line 531 + 9 bytes
node_list_wrapper_dtor(_xmlNode * 0x005c3c18) line 521 + 12 bytes
php_free_xml_doc(_zend_rsrc_list_entry * 0x00e38e18, void * * *
0x00afe7a8) line 563 + 12 bytes
list_entry_destructor(void * 0x00e38e18) line 177 + 16 bytes
zend_hash_apply_deleter(_hashtable * 0x00b2cac4, bucket * 0x00e38db8)
line 596 + 15 bytes
zend_hash_graceful_reverse_destroy(_hashtable * 0x00b2cac4) line 662 +
13 bytes
zend_destroy_rsrc_list(_hashtable * 0x00b2cac4, void * * * 0x00afe7a8)
line 233 + 9 bytes
shutdown_executor(void * * * 0x00afe7a8) line 196 + 30 bytes
zend_deactivate(void * * * 0x00afe7a8) line 596 + 9 bytes
php_request_shutdown(void * 0x) line 787 + 9 bytes
apache_php_module_main(request_rec * 0x00afc798, int 0x, void *
* * 0x00afe7a8) line 96 + 8 bytes
send_php(request_rec * 0x00afc798, int 0x, char * 0x00afd248)
line 575 + 17 bytes
send_parsed_php(request_rec * 0x00afc798) line 590 + 13 bytes
ap_invoke_handler(request_rec * 0x00afc798) line 517 + 10 bytes
process_request_internal(request_rec * 0x00afc798) line 1308 + 9 bytes
ap_process_request(request_rec * 0x00afc798) line 1324 + 9 bytes
child_sub_main(int 0x) line 5881




The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/16888

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




Bug #17272 Updated: Failure to read Flash MX file size

2002-05-17 Thread derick

 ID:   17272
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Suspended
 Bug Type: Feature/Change Request
 Operating System: N/A
 PHP Version:  4.1.2
 New Comment:

I'm suspending this until somebody can show me some documentation on
the new fileformat. Apperently there are two Flash 6 formats, the SWF
one (which works fine and is the same as Flash 5) and the SWC one,
which is some compressed format.

Derick


Previous Comments:


[2002-05-16 13:22:22] [EMAIL PROTECTED]

Not really a bug, as it was not written for this :)
Anyway, if you could mail me  empty flash movies with the following
size, I'll see what I can do:

255x127
640x480
400x256
(and perhaps some more)

Derick



[2002-05-16 12:22:48] [EMAIL PROTECTED]

The problem is with the getimagesize() function and its detection
routines which don't detect Flash 6/MX content.



[2002-05-16 12:00:44] [EMAIL PROTECTED]

Flash file size detection seems to not work for Flash files published
in the new Flash MX (version 6).  When published to version 5 or
lower, it works.




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




Bug #17293: Environment variables

2002-05-17 Thread cris

From: [EMAIL PROTECTED]
Operating system: SuSE Linux 8
PHP version:  4.2.1
PHP Bug Type: *General Issues
Bug description:  Environment variables 

I've upgraded PHP from 4.1.2 to 4.2.1 and all variables passed via url
parameters are empty.
For example:

http://mysite.com/detail.php?order=1sid=15

inside detail.php $order and $sid are not set.

I have to modify all the pages to include things like:

$sid=$HTTP_GET_VARS['sid'];

and then sid get the desired value (15).

I've compiled this version exactly the same way as 4.1.2 and in the older
version it works ok (under SuSE 8).

Files  versions:

 apache_1.3.24.tar.gz
 c-client.tar.Z
 mod_ssl-2.8.8-1.3.24.tar.gz
 openssl-0.9.6c.tar.gz
 php-4.2.1.tar.gz   and  php-4.1.2.tar.gz

---
The following is the script I used to compile:

# Instalación de apache (1ra. parte)
# --
tar zxf apache_1.3.24.tar.gz
cd apache_1.3.24
./configure --prefix=/webmail
cd ..

# Instalación de OpenSSL
# --

tar zxf openssl-0.9.6c.tar.gz
cd openssl-0.9.6c
./config
make
make test
make install
cd ..

# Instalación de Mod_SSL sin certificado
# --

tar zxf mod_ssl-2.8.8-1.3.24.tar.gz 
cd mod_ssl-2.8.8-1.3.24
./configure \
--with-apache=../apache_1.3.24 \
--with-ssl=../openssl-0.9.6c \
--prefix=/webmail
cd ..

# Librería c-client para IMAP
# ---

tar zxf c-client.tar.Z
cd imap-2001.BETA.SNAP-0107221451/
make slx

cp c-client/c-client.a /usr/local/lib/c-client.a
cp c-client/rfc822.h /usr/local/include 
cp c-client/mail.h /usr/local/include
cp c-client/linkage.h /usr/local/include
cd ..


# Instalación de php4
# ---

tar zxf php-4.2.1.tar.gz
cd php-4.2.1
./configure --with-mysql --with-apache=../apache_1.3.24
--enable-track-vars --with-imap --with-oci8
make
make install
cp php.ini-dist /usr/local/lib/php.ini
cd ..

cd apache_1.3.24
./configure --prefix=/webmail --activate-module=src/modules/php4/libphp4.a
--enable-module=ssl
make
make certificate TYPE=custom

make install

--
And then in httpd.conf:
DirectoryIndex index.html index.php index.php3

AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
AddType application/x-httpd-php .php3
-- 
Edit bug report at http://bugs.php.net/?id=17293edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17293r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17293r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17293r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17293r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17293r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17293r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17293r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17293r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17293r=globals




Bug #15333 Updated: strndup access violation

2002-05-17 Thread agustinchernitsky

 ID:   15333
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Critical
 Bug Type: IIS related
 Operating System: Windows 2000 Pro
 PHP Version:  4.2.0 RC2
 New Comment:

Running PHP 4.2.1
Win2K Server with all Security Updates

Still getting the ISAPI module error. My event Log shows:

Event Type: Warning
Event Source:   W3SVC
Event Category: None
Event ID:   36
Date:   17/05/2002
Time:   14:09:30
User:   N/A
Computer:   SERVER2
Description:
The server failed to load application '/LM/W3SVC/24/Root/admin'.  The
error was 'The application called an interface that was marshalled for
a different thread.
'. 
For additional information specific to this message please visit the
Microsoft Online Support site located at:
http://www.microsoft.com/contentredirect.asp. 


Where /Root/admin is the virtual dir running PHP files.


Previous Comments:


[2002-05-15 10:23:32] [EMAIL PROTECTED]

I beleive that is what it was being called when I downloaded it, maybe
I am mistaken.

Anyway I am now running php 4.2.1 and am having the same problem.

Windows 2000 Server
Stock PHP 4.2.1 install
Stock MySQL 3.29 install
Stock phpBB 2.0 install

The HTTP server encountered an unhandled exception while processing the
ISAPI Application '
php4ts!zend_strndup + 0x2B
 + 0xA05E5983




[2002-05-14 17:46:39] [EMAIL PROTECTED]

Uh, PHP 2.0 Gold?  What the heck is that?



[2002-05-14 17:08:08] [EMAIL PROTECTED]

Any update to this?  Using PHP 2.0 Gold and still haveing this problm:

php4ts!zend_strndup + 0x2B



[2002-05-10 04:22:01] [EMAIL PROTECTED]

I've got the same configuration (win2k, iis5 and mssql via obdc) the
machine want to run propperly and i've seen the same errors. now, php
is configured in the applications mappings AND in the isapi filters
(seen here somewhere as a hint). the site is stored in a fully
configured virtual host ( assign ip-address, assigned host name, cache
scripts etc etc). now, it runs stable without any of the strange errors
described in the other postings. dont ask me why, i'm not really happy
but so far it's a prove that the mission impossible became reality
;-) and it had cost me some hard days to make it true.

btw: no zend encode or optimizer is installed



[2002-04-23 18:35:20] [EMAIL PROTECTED]

how do I go about running 'tkill'?



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/15333

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




Bug #17293 Updated: Environment variables

2002-05-17 Thread rasmus

 ID:   17293
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: SuSE Linux 8
 PHP Version:  4.2.1
 New Comment:

In PHP 4.2.0, the 'register_globals' setting default changed to
be off. See http://www.php.net/release_4_2_0.php for more info.
We are sorry about the inconvenience, but this change was a necessary
part of our efforts to make PHP scripting more secure and portable.


Previous Comments:


[2002-05-17 13:34:27] [EMAIL PROTECTED]

I've upgraded PHP from 4.1.2 to 4.2.1 and all variables passed via url
parameters are empty.
For example:

http://mysite.com/detail.php?order=1sid=15

inside detail.php $order and $sid are not set.

I have to modify all the pages to include things like:

$sid=$HTTP_GET_VARS['sid'];

and then sid get the desired value (15).

I've compiled this version exactly the same way as 4.1.2 and in the
older version it works ok (under SuSE 8).

Files  versions:

 apache_1.3.24.tar.gz
 c-client.tar.Z
 mod_ssl-2.8.8-1.3.24.tar.gz
 openssl-0.9.6c.tar.gz
 php-4.2.1.tar.gz   and  php-4.1.2.tar.gz

---
The following is the script I used to compile:

# Instalación de apache (1ra. parte)
# --
tar zxf apache_1.3.24.tar.gz
cd apache_1.3.24
./configure --prefix=/webmail
cd ..

# Instalación de OpenSSL
# --

tar zxf openssl-0.9.6c.tar.gz
cd openssl-0.9.6c
./config
make
make test
make install
cd ..

# Instalación de Mod_SSL sin certificado
# --

tar zxf mod_ssl-2.8.8-1.3.24.tar.gz 
cd mod_ssl-2.8.8-1.3.24
./configure \
--with-apache=../apache_1.3.24 \
--with-ssl=../openssl-0.9.6c \
--prefix=/webmail
cd ..

# Librería c-client para IMAP
# ---

tar zxf c-client.tar.Z
cd imap-2001.BETA.SNAP-0107221451/
make slx

cp c-client/c-client.a /usr/local/lib/c-client.a
cp c-client/rfc822.h /usr/local/include 
cp c-client/mail.h /usr/local/include
cp c-client/linkage.h /usr/local/include
cd ..


# Instalación de php4
# ---

tar zxf php-4.2.1.tar.gz
cd php-4.2.1
./configure --with-mysql --with-apache=../apache_1.3.24
--enable-track-vars --with-imap --with-oci8
make
make install
cp php.ini-dist /usr/local/lib/php.ini
cd ..

cd apache_1.3.24
./configure --prefix=/webmail
--activate-module=src/modules/php4/libphp4.a --enable-module=ssl
make
make certificate TYPE=custom

make install

--
And then in httpd.conf:
DirectoryIndex index.html index.php index.php3

AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
AddType application/x-httpd-php .php3




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




Bug #13519 Updated: Filename time.h conflict in VS.NET

2002-05-17 Thread faisal

 ID:   13519
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Compile Failure
 Operating System: Windows 2000 SP2
 PHP Version:  4.0.6
 New Comment:

php 4.2.1 compiles on VS.NET Beta 2 without a glitch... just had to
change all the project entries to same config (I used Release_TS).


Previous Comments:


[2002-05-17 12:29:22] [EMAIL PROTECTED]

I think people already reported that it works with VS.NET, can you give
it a try with latest sources?



[2001-10-02 15:09:24] [EMAIL PROTECTED]

again vs.net is not yet supported.
actually php's time.h includes the system time.h so i don't know what
the change is going to resolve...
maybe something's messed with your include paths.



[2001-10-02 14:52:32] [EMAIL PROTECTED]

Whoops!  There are a _lot_ more than just those two files that require
time.h to be changed to  _time.h.  Lousy non-regex search :)



[2001-10-02 14:46:27] [EMAIL PROTECTED]

I _believe_ this issue only applies to VS.NET, but have not tested it
in earlier versions.

Using Visual Studio 7.0 build 9254 (VS.NET Beta 2), the build of
time.c and sendmail.c fail because header time.h fails to be
included.  Checking the sources, it is absolutely impossible for the
#include time.h statement not to be compiled, but the statement
appeared to be ignored anyway.

When the filename of time.h (in /win32) is changed to _time.h and
the approriate #include lines in time.c and sendmail.c are
modified, compilation succeeds normally.  A little testing showed that
VS.NET was including time.h (part of php4) instead of time.h (part
of msvcrt.dll).  Once the filename conflict was resolved, the correct
file was included.




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




Bug #17281 Updated: session_encode is causing segmentation fault

2002-05-17 Thread rubens_gomes

 ID:   17281
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Session related
 Operating System: Solaris 2.7
 PHP Version:  4.2.1
 New Comment:

bash-2.03# gdb /usr/local/apache/bin/httpd
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as sparc-sun-solaris2.7...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
[New LWP2]
[New LWP3]
[New LWP4]

Program received signal SIGSEGV, Segmentation fault.
0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, __zend_filename=0xfe75c060
zend_execute_API.c, 
__zend_lineno=274) at zend_variables.c:43
43  CHECK_ZVAL_STRING_REL(zvalue);
(gdb) bt
#0  0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, 
__zend_filename=0xfe75c060 zend_execute_API.c,
__zend_lineno=274)
at zend_variables.c:43
#1  0xfe5dde08 in _zval_ptr_dtor (zval_ptr=0xfe7aac78, 
__zend_filename=0xfe75ba90 zend_execute_locks.h,
__zend_lineno=26)
at zend_execute_API.c:274
#2  0xfe5db0d8 in zend_clean_garbage () at zend_execute_locks.h:26
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
#4  0xfe5d933c in execute (op_array=0x13de78) at ./zend_execute.c:2141
#5  0xfe5ef554 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:810
#6  0xfe60b958 in php_execute_script (primary_file=0xffbeecb0) at
main.c:1381
#7  0xfe603b94 in apache_php_module_main (r=0x131558,
display_source_mode=0)
at sapi_apache.c:90
#8  0xfe605170 in send_php (r=0x131558, display_source_mode=0, 
filename=0x132078 /home/httpd/html/dbiflex/sm/login.php) at
mod_php4.c:575
#9  0xfe6051e8 in send_parsed_php (r=0x131558) at mod_php4.c:590
#10 0x41620 in ap_invoke_handler () from /lib/libaio.so.1
#11 0x5fd04 in process_request_internal () from /lib/libaio.so.1
#12 0x5fd88 in ap_process_request () from /lib/libaio.so.1
#13 0x52f74 in child_main () from /lib/libaio.so.1
#14 0x53208 in make_child () from /lib/libaio.so.1
#15 0x53424 in startup_children () from /lib/libaio.so.1
#16 0x53e58 in standalone_main () from /lib/libaio.so.1
#17 0x54aa0 in main () from /lib/libaio.so.1
(gdb) frame 3
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
1056zend_clean_garbage(TSRMLS_C);
(gdb) print (char
*)(executor_globals.function_state_ptr-function)-common.function_name
$1 = 0x0
(gdb) print (char *)executor_globals.active_op_array-function_name
$2 = 0x0
(gdb) print (char *)executor_globals.active_op_array-filename
$3 = 0x14a970
/home/nmsuser/dbiflex/docroot/common/page_login_header.inc
(gdb) quit
The program is running.  Exit anyway? (y or n) y


Here is the line that is causing the seg fault:

error_log( {common/page_login_header.inc session_encode:  .
session_encode() );


Previous Comments:


[2002-05-17 04:37:13] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php

Once you have generated a backtrace, please submit it to this bug
report and change the status back to Open. Thank you for helping
us make PHP better.





[2002-05-16 19:56:38] [EMAIL PROTECTED]

I am running apache 1.3.24/PHP 4.2.1 on Solaris 2.7 (with
recent OS patches applied.)

When I call session_encode() as follows I get the 
segmentation fault error below...

$session_array = explode(;, session_encode());

[Thu May 16 20:50:45 2002] [notice] child pid 26235 exit signal
Segmentation Fault (11)

Rubens.




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




Bug #17294: session_encode() fails with segmentation fault

2002-05-17 Thread rubens_gomes

From: [EMAIL PROTECTED]
Operating system: Solaris 2.7
PHP version:  4.2.1
PHP Bug Type: Session related
Bug description:  session_encode() fails with segmentation fault

I am running apache 1.3.24/PHP 4.2.1 on Solaris 2.7 (with
recent OS patches applied.)

When I call session_encode() as follows I get the 
segmentation fault error below...

$session_array = explode(;, session_encode());

Following is backtrace ...

[bash-2.03# gdb /usr/local/apache/bin/httpd
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as sparc-sun-solaris2.7...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
[New LWP2]
[New LWP3]
[New LWP4]

Program received signal SIGSEGV, Segmentation fault.
0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, __zend_filename=0xfe75c060
zend_execute_API.c, 
__zend_lineno=274) at zend_variables.c:43
43  CHECK_ZVAL_STRING_REL(zvalue);
(gdb) bt
#0  0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, 
__zend_filename=0xfe75c060 zend_execute_API.c, __zend_lineno=274)
at zend_variables.c:43
#1  0xfe5dde08 in _zval_ptr_dtor (zval_ptr=0xfe7aac78, 
__zend_filename=0xfe75ba90 zend_execute_locks.h,
__zend_lineno=26)
at zend_execute_API.c:274
#2  0xfe5db0d8 in zend_clean_garbage () at zend_execute_locks.h:26
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
#4  0xfe5d933c in execute (op_array=0x13de78) at ./zend_execute.c:2141
#5  0xfe5ef554 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:810
#6  0xfe60b958 in php_execute_script (primary_file=0xffbeecb0) at
main.c:1381
#7  0xfe603b94 in apache_php_module_main (r=0x131558,
display_source_mode=0)
at sapi_apache.c:90
#8  0xfe605170 in send_php (r=0x131558, display_source_mode=0, 
filename=0x132078 /home/httpd/html/dbiflex/sm/login.php) at
mod_php4.c:575
#9  0xfe6051e8 in send_parsed_php (r=0x131558) at mod_php4.c:590
#10 0x41620 in ap_invoke_handler () from /lib/libaio.so.1
#11 0x5fd04 in process_request_internal () from /lib/libaio.so.1
#12 0x5fd88 in ap_process_request () from /lib/libaio.so.1
#13 0x52f74 in child_main () from /lib/libaio.so.1
#14 0x53208 in make_child () from /lib/libaio.so.1
#15 0x53424 in startup_children () from /lib/libaio.so.1
#16 0x53e58 in standalone_main () from /lib/libaio.so.1
#17 0x54aa0 in main () from /lib/libaio.so.1
(gdb) frame 3
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
1056zend_clean_garbage(TSRMLS_C);
(gdb) print (char
*)(executor_globals.function_state_ptr-function)-common.function_name
$1 = 0x0
(gdb) print (char *)executor_globals.active_op_array-function_name
$2 = 0x0
(gdb) print (char *)executor_globals.active_op_array-filename
$3 = 0x14a970
/home/nmsuser/dbiflex/docroot/common/page_login_header.inc
(gdb) quit
The program is running.  Exit anyway? (y or n) y


Here is the line that is causing the seg fault:

error_log( {common/page_login_header.inc session_encode:  .
session_encode() );

-- 
Edit bug report at http://bugs.php.net/?id=17294edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17294r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17294r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17294r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17294r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17294r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17294r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17294r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17294r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17294r=globals




Bug #17289 Updated: missing word in german translation

2002-05-17 Thread tom

 ID:   17289
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Documentation problem
 Operating System: N.A.
 PHP Version:  4.2.1
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.

Thanks for the note!


Previous Comments:


[2002-05-17 10:42:23] [EMAIL PROTECTED]

in http://de.php.net/manual/de/class.variant.php 
(german translation of the manual):

VARIANT

(unknown)
VARIANT -- VARIANT Klasse
Synopsis

$vVar = new VARIANT($var)

Beschreibung

Ein einfacher Container, um Variablen VARIANT Strukturen zu verpacken.


There is missing the word 'in' between 'Variablen' and 'VARIANT'. The
correct sentence must be something like:

Ein einfacher Container, um Variablen in VARIANT Strukturen zu
verpacken. 






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




Bug #17081 Updated: $_GET != $HTTP_GET_VARS

2002-05-17 Thread tom

 ID:   17081
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: Documentation problem
 Operating System: RH 7.2
 PHP Version:  4.2.0
 New Comment:

This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2002-05-07 17:10:04] [EMAIL PROTECTED]

This is not really a bug, making this a documentation issue.

Derick



[2002-05-07 15:58:11] [EMAIL PROTECTED]

There is a problem with $_GET and $HTTP_GET_VARS. In documentation, in
Predefined Variables is mentioned:

$HTTP_GET_VARS contains the same information, but is not an
autoglobal.

That's true only in one condition - when we are talking about REAL
variables passed by GET. But when we set one variable explicity in
$HTTP_GET_VARS it is doesn't set in $_GET and vice versa, ie:

$HTTP_GET_VARS[sthnew] = some str;
echo $_GET[sthnew]; // There is no such index

And:

$_GET[sthnew] = some str;
echo $HTTP_GET_VARS[sthnew]; // There is no such index

but !!

$HTTP_SESSION_VARS[sthnew] = some str;
echo $_SESSION[sthnew]; // Everything is OK

I know that _GET and HTTP_GET_VARS shouldn't be set explicity, but I'm
doing sth like URL coding and decoding to hide variables from being
watched by users and I'm coding also session id. After decoding I write
session sid in HTTP_GET_VARS and call session_start(). But
session_start() use _only_ $_GET array, not $HTTP_GET_VARS and of
course sessions doesn't work. 

I think you should change documentation or change this feature :) When
I read: $HTTP_GET_VARS contains the same information... it means for
me THE SAME ALL THE TIME... If it doesn't it is very confusing :(
Especially that $_SESSION and $HTTP_SESSION_VARS contains the same
information all the time.

Adam




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




Bug #17295: Bug in while statement

2002-05-17 Thread pahowes

From: [EMAIL PROTECTED]
Operating system: FreeBSD 4.5
PHP version:  4.2.0
PHP Bug Type: Scripting Engine problem
Bug description:  Bug in while statement

I was following one of the samples in the MySQL section of the manual to
extract data from a table, and ran into the following:

If you have a class that handles the database access (I called it
DBManager:

class DBManager
{
  var $link;
  var $result;

  function connect( )
  {
$this-link = mysql_pconnect( 'hostname', 'username', 'password' );
mysql_select_db( 'dbname', $this-link );
  }

  function query( $q )
  {
$this-result = mysql_query( $q, $this-link );
return( $this-result );
  }

  function next_row( )
  {
$row = mysql_fetch_array( $this-result ) or
  die( error:  . mysql_error( ) );
return( $row );
  }
};

The sample in the documentation works fine:

$link = mysql_connect( 'hostname', 'username', 'password' );
mysql_select_db( 'dbname', $link );
$q = SELECT * FROM user;
$result = mysql_query( $q );
while( $row = mysql_fetch_array( $result ) )
{
  echo $row['username'];
}

When replaced with the object above:

$db = new DBManager( )
$db-connect( );
$q = SELECT * FROM user;
$result = $db-query( $q );
while( $row = $db-next_row( ) )
{
  echo $row['username'];
}

...Fetching the next row will fail with no error message from MySQL (the
return value from the call to mysql_error is empty.)

I think this is a bug in the scripting engine itself.  Using a function
call in the while condition works fine, but using a class-function call
causes an error.  If the $row = $db-next_row( ) statement appears
anywhere else, it will work fine.

--
Paul A. Howes
[EMAIL PROTECTED]

-- 
Edit bug report at http://bugs.php.net/?id=17295edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17295r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17295r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17295r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17295r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17295r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17295r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17295r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17295r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17295r=globals




Bug #17297: TEXTAREA and PHPSESSID

2002-05-17 Thread needleboy

From: [EMAIL PROTECTED]
Operating system: winME
PHP version:  4.1.2
PHP Bug Type: Session related
Bug description:  TEXTAREA and PHPSESSID

i didna compile PHP

the php session adds ?PHPSESSID vars into html inside a textarea, which
causes hassles when you're using a textarea to store html code in the db.

perhaps this has been dealt with, and if so, i apologise, but i couldna
find it.

in advance, thankyou
-- 
Edit bug report at http://bugs.php.net/?id=17297edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17297r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17297r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17297r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17297r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17297r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17297r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17297r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17297r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17297r=globals




Bug #17294 Updated: session_encode() fails with segmentation fault

2002-05-17 Thread sniper

 ID:   17294
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Duplicate
 Bug Type: Session related
 Operating System: Solaris 2.7
 PHP Version:  4.2.1
 New Comment:

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments
to the original bug instead.

Thank you for your interest in PHP.


Previous Comments:


[2002-05-17 14:25:25] [EMAIL PROTECTED]

I am running apache 1.3.24/PHP 4.2.1 on Solaris 2.7 (with
recent OS patches applied.)

When I call session_encode() as follows I get the 
segmentation fault error below...

$session_array = explode(;, session_encode());

Following is backtrace ...

[bash-2.03# gdb /usr/local/apache/bin/httpd
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as sparc-sun-solaris2.7...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
[New LWP2]
[New LWP3]
[New LWP4]

Program received signal SIGSEGV, Segmentation fault.
0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, __zend_filename=0xfe75c060
zend_execute_API.c, 
__zend_lineno=274) at zend_variables.c:43
43  CHECK_ZVAL_STRING_REL(zvalue);
(gdb) bt
#0  0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, 
__zend_filename=0xfe75c060 zend_execute_API.c,
__zend_lineno=274)
at zend_variables.c:43
#1  0xfe5dde08 in _zval_ptr_dtor (zval_ptr=0xfe7aac78, 
__zend_filename=0xfe75ba90 zend_execute_locks.h,
__zend_lineno=26)
at zend_execute_API.c:274
#2  0xfe5db0d8 in zend_clean_garbage () at zend_execute_locks.h:26
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
#4  0xfe5d933c in execute (op_array=0x13de78) at ./zend_execute.c:2141
#5  0xfe5ef554 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:810
#6  0xfe60b958 in php_execute_script (primary_file=0xffbeecb0) at
main.c:1381
#7  0xfe603b94 in apache_php_module_main (r=0x131558,
display_source_mode=0)
at sapi_apache.c:90
#8  0xfe605170 in send_php (r=0x131558, display_source_mode=0, 
filename=0x132078 /home/httpd/html/dbiflex/sm/login.php) at
mod_php4.c:575
#9  0xfe6051e8 in send_parsed_php (r=0x131558) at mod_php4.c:590
#10 0x41620 in ap_invoke_handler () from /lib/libaio.so.1
#11 0x5fd04 in process_request_internal () from /lib/libaio.so.1
#12 0x5fd88 in ap_process_request () from /lib/libaio.so.1
#13 0x52f74 in child_main () from /lib/libaio.so.1
#14 0x53208 in make_child () from /lib/libaio.so.1
#15 0x53424 in startup_children () from /lib/libaio.so.1
#16 0x53e58 in standalone_main () from /lib/libaio.so.1
#17 0x54aa0 in main () from /lib/libaio.so.1
(gdb) frame 3
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
1056zend_clean_garbage(TSRMLS_C);
(gdb) print (char
*)(executor_globals.function_state_ptr-function)-common.function_name
$1 = 0x0
(gdb) print (char *)executor_globals.active_op_array-function_name
$2 = 0x0
(gdb) print (char *)executor_globals.active_op_array-filename
$3 = 0x14a970
/home/nmsuser/dbiflex/docroot/common/page_login_header.inc
(gdb) quit
The program is running.  Exit anyway? (y or n) y


Here is the line that is causing the seg fault:

error_log( {common/page_login_header.inc session_encode:  .
session_encode() );





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




Bug #17294 Updated: session_encode() fails with segmentation fault

2002-05-17 Thread sniper

 ID:   17294
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Duplicate
+Status:   Bogus
 Bug Type: Session related
 Operating System: Solaris 2.7
 PHP Version:  4.2.1


Previous Comments:


[2002-05-17 17:57:44] [EMAIL PROTECTED]

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments
to the original bug instead.

Thank you for your interest in PHP.



[2002-05-17 14:25:25] [EMAIL PROTECTED]

I am running apache 1.3.24/PHP 4.2.1 on Solaris 2.7 (with
recent OS patches applied.)

When I call session_encode() as follows I get the 
segmentation fault error below...

$session_array = explode(;, session_encode());

Following is backtrace ...

[bash-2.03# gdb /usr/local/apache/bin/httpd
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as sparc-sun-solaris2.7...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
[New LWP2]
[New LWP3]
[New LWP4]

Program received signal SIGSEGV, Segmentation fault.
0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, __zend_filename=0xfe75c060
zend_execute_API.c, 
__zend_lineno=274) at zend_variables.c:43
43  CHECK_ZVAL_STRING_REL(zvalue);
(gdb) bt
#0  0xfe5ec8c4 in _zval_dtor (zvalue=0x1586b0, 
__zend_filename=0xfe75c060 zend_execute_API.c,
__zend_lineno=274)
at zend_variables.c:43
#1  0xfe5dde08 in _zval_ptr_dtor (zval_ptr=0xfe7aac78, 
__zend_filename=0xfe75ba90 zend_execute_locks.h,
__zend_lineno=26)
at zend_execute_API.c:274
#2  0xfe5db0d8 in zend_clean_garbage () at zend_execute_locks.h:26
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
#4  0xfe5d933c in execute (op_array=0x13de78) at ./zend_execute.c:2141
#5  0xfe5ef554 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:810
#6  0xfe60b958 in php_execute_script (primary_file=0xffbeecb0) at
main.c:1381
#7  0xfe603b94 in apache_php_module_main (r=0x131558,
display_source_mode=0)
at sapi_apache.c:90
#8  0xfe605170 in send_php (r=0x131558, display_source_mode=0, 
filename=0x132078 /home/httpd/html/dbiflex/sm/login.php) at
mod_php4.c:575
#9  0xfe6051e8 in send_parsed_php (r=0x131558) at mod_php4.c:590
#10 0x41620 in ap_invoke_handler () from /lib/libaio.so.1
#11 0x5fd04 in process_request_internal () from /lib/libaio.so.1
#12 0x5fd88 in ap_process_request () from /lib/libaio.so.1
#13 0x52f74 in child_main () from /lib/libaio.so.1
#14 0x53208 in make_child () from /lib/libaio.so.1
#15 0x53424 in startup_children () from /lib/libaio.so.1
#16 0x53e58 in standalone_main () from /lib/libaio.so.1
#17 0x54aa0 in main () from /lib/libaio.so.1
(gdb) frame 3
#3  0xfe5d2b8c in execute (op_array=0x1436e8) at ./zend_execute.c:1056
1056zend_clean_garbage(TSRMLS_C);
(gdb) print (char
*)(executor_globals.function_state_ptr-function)-common.function_name
$1 = 0x0
(gdb) print (char *)executor_globals.active_op_array-function_name
$2 = 0x0
(gdb) print (char *)executor_globals.active_op_array-filename
$3 = 0x14a970
/home/nmsuser/dbiflex/docroot/common/page_login_header.inc
(gdb) quit
The program is running.  Exit anyway? (y or n) y


Here is the line that is causing the seg fault:

error_log( {common/page_login_header.inc session_encode:  .
session_encode() );





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




Bug #17298: stristr is not case-insensitive with scandinavian alphabets

2002-05-17 Thread hannu . maksimainen

From: [EMAIL PROTECTED]
Operating system: linux 2.4.18
PHP version:  4.2.0
PHP Bug Type: Strings related
Bug description:  stristr is not case-insensitive with scandinavian alphabets

I have a string There are Ä and ä in scandinavian alphabets.

I want stristr function to return everything after the first occurence of
ä (capital Ä in this case) in my script:

$str = There are Ä and ä in scandinavian alphabets;
echo stristr($str, ä);

It returns ä in scandinavian alphabets.
It should return Ä and ä in scandinavian alphabets.

--
With 'normal' alphabets it works ok. Like this:

$str = There are B and b in scandinavian alphabets;
echo stristr($str, b);

and it returns B and b in scandinavian alphabets
-- 
Edit bug report at http://bugs.php.net/?id=17298edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17298r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17298r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17298r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17298r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17298r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17298r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17298r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17298r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17298r=globals




Bug #17295 Updated: Bug in while statement

2002-05-17 Thread sniper

 ID:   17295
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 4.5
 PHP Version:  4.2.0
 New Comment:

What if you remove that bogus 'die(..)' stuff from the
function? It now dies when there are no more rows.




Previous Comments:


[2002-05-17 16:51:06] [EMAIL PROTECTED]

I was following one of the samples in the MySQL section of the manual
to extract data from a table, and ran into the following:

If you have a class that handles the database access (I called it
DBManager:

class DBManager
{
  var $link;
  var $result;

  function connect( )
  {
$this-link = mysql_pconnect( 'hostname', 'username', 'password'
);
mysql_select_db( 'dbname', $this-link );
  }

  function query( $q )
  {
$this-result = mysql_query( $q, $this-link );
return( $this-result );
  }

  function next_row( )
  {
$row = mysql_fetch_array( $this-result ) or
  die( error:  . mysql_error( ) );
return( $row );
  }
};

The sample in the documentation works fine:

$link = mysql_connect( 'hostname', 'username', 'password' );
mysql_select_db( 'dbname', $link );
$q = SELECT * FROM user;
$result = mysql_query( $q );
while( $row = mysql_fetch_array( $result ) )
{
  echo $row['username'];
}

When replaced with the object above:

$db = new DBManager( )
$db-connect( );
$q = SELECT * FROM user;
$result = $db-query( $q );
while( $row = $db-next_row( ) )
{
  echo $row['username'];
}

...Fetching the next row will fail with no error message from MySQL
(the return value from the call to mysql_error is empty.)

I think this is a bug in the scripting engine itself.  Using a function
call in the while condition works fine, but using a class-function call
causes an error.  If the $row = $db-next_row( ) statement appears
anywhere else, it will work fine.

--
Paul A. Howes
[EMAIL PROTECTED]





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




Bug #17297 Updated: TEXTAREA and PHPSESSID

2002-05-17 Thread sniper

 ID:   17297
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Feedback
 Bug Type: Session related
 Operating System: winME
 PHP Version:  4.1.2
 New Comment:

Please add an example piece of HTML which can be used to 
reproduce this.



Previous Comments:


[2002-05-17 17:03:09] [EMAIL PROTECTED]

i didna compile PHP

the php session adds ?PHPSESSID vars into html inside a textarea, which
causes hassles when you're using a textarea to store html code in the
db.

perhaps this has been dealt with, and if so, i apologise, but i couldna
find it.

in advance, thankyou




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




Bug #17298 Updated: stristr is not case-insensitive with scandinavian alphabets

2002-05-17 Thread sniper

 ID:   17298
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Feedback
 Bug Type: Strings related
 Operating System: linux 2.4.18
 PHP Version:  4.2.0
 New Comment:

I can't reproduce this..it might be some locale issue.
Which linux distro?

--Jani



Previous Comments:


[2002-05-17 18:04:34] [EMAIL PROTECTED]

I have a string There are Ä and ä in scandinavian alphabets.

I want stristr function to return everything after the first occurence
of ä (capital Ä in this case) in my script:

$str = There are Ä and ä in scandinavian alphabets;
echo stristr($str, ä);

It returns ä in scandinavian alphabets.
It should return Ä and ä in scandinavian alphabets.

--
With 'normal' alphabets it works ok. Like this:

$str = There are B and b in scandinavian alphabets;
echo stristr($str, b);

and it returns B and b in scandinavian alphabets




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




Bug #17297 Updated: TEXTAREA and PHPSESSID

2002-05-17 Thread needleboy

 ID:   17297
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Session related
 Operating System: winME
 PHP Version:  4.1.2
 New Comment:

textareaa href=index.htmllink/a/textarea

will be rendered to

textareaa
href=index.html?PHPSESSID=sdhf87akjdasjd878a8sf...link/a/textarea

with cookies turned off, but php sessions used

thankyou for the swift response


Previous Comments:


[2002-05-17 18:08:42] [EMAIL PROTECTED]

Please add an example piece of HTML which can be used to 
reproduce this.




[2002-05-17 17:03:09] [EMAIL PROTECTED]

i didna compile PHP

the php session adds ?PHPSESSID vars into html inside a textarea, which
causes hassles when you're using a textarea to store html code in the
db.

perhaps this has been dealt with, and if so, i apologise, but i couldna
find it.

in advance, thankyou




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




Bug #17298 Updated: stristr is not case-insensitive with scandinavian alphabets

2002-05-17 Thread hannu . maksimainen

 ID:   17298
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Strings related
 Operating System: linux 2.4.18
 PHP Version:  4.2.0
 New Comment:

Mandrake 7.2 with kernel 2.4.18
apache 2.0.35
php 4.2.0

I also tested this with my friend's server and it didn't work there
either. He has Debian Linux (2.4.16 kernel) with apache 1.3.23 and php
4.1.2.


Previous Comments:


[2002-05-17 18:13:38] [EMAIL PROTECTED]

I can't reproduce this..it might be some locale issue.
Which linux distro?

--Jani




[2002-05-17 18:04:34] [EMAIL PROTECTED]

I have a string There are Ä and ä in scandinavian alphabets.

I want stristr function to return everything after the first occurence
of ä (capital Ä in this case) in my script:

$str = There are Ä and ä in scandinavian alphabets;
echo stristr($str, ä);

It returns ä in scandinavian alphabets.
It should return Ä and ä in scandinavian alphabets.

--
With 'normal' alphabets it works ok. Like this:

$str = There are B and b in scandinavian alphabets;
echo stristr($str, b);

and it returns B and b in scandinavian alphabets




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




Bug #17298 Updated: stristr is not case-insensitive with scandinavian alphabets

2002-05-17 Thread sniper

 ID:   17298
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Bogus
 Bug Type: Strings related
 Operating System: linux 2.4.18
 PHP Version:  4.2.0
 New Comment:

It's really a locale issue. Not PHP problem in, you just need to set
the locale correctly.

Either via environment var LC_ALL or setting it in the script with
setlocale(), e.g.:

setlocale(LC_ALL, fi_FI);

--Jani



Previous Comments:


[2002-05-17 18:40:04] [EMAIL PROTECTED]

Mandrake 7.2 with kernel 2.4.18
apache 2.0.35
php 4.2.0

I also tested this with my friend's server and it didn't work there
either. He has Debian Linux (2.4.16 kernel) with apache 1.3.23 and php
4.1.2.



[2002-05-17 18:13:38] [EMAIL PROTECTED]

I can't reproduce this..it might be some locale issue.
Which linux distro?

--Jani




[2002-05-17 18:04:34] [EMAIL PROTECTED]

I have a string There are Ä and ä in scandinavian alphabets.

I want stristr function to return everything after the first occurence
of ä (capital Ä in this case) in my script:

$str = There are Ä and ä in scandinavian alphabets;
echo stristr($str, ä);

It returns ä in scandinavian alphabets.
It should return Ä and ä in scandinavian alphabets.

--
With 'normal' alphabets it works ok. Like this:

$str = There are B and b in scandinavian alphabets;
echo stristr($str, b);

and it returns B and b in scandinavian alphabets




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




Bug #17297 Updated: TEXTAREA and PHPSESSID

2002-05-17 Thread sniper

 ID:   17297
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Bogus
 Bug Type: Session related
 Operating System: winME
 PHP Version:  4.1.2
 New Comment:

This is not bug but pretty much the expected behaviour.
You should use htmlentities() on the data for textarea

--Jani



Previous Comments:


[2002-05-17 18:31:58] [EMAIL PROTECTED]

textareaa href=index.htmllink/a/textarea

will be rendered to

textareaa
href=index.html?PHPSESSID=sdhf87akjdasjd878a8sf...link/a/textarea

with cookies turned off, but php sessions used

thankyou for the swift response



[2002-05-17 18:08:42] [EMAIL PROTECTED]

Please add an example piece of HTML which can be used to 
reproduce this.




[2002-05-17 17:03:09] [EMAIL PROTECTED]

i didna compile PHP

the php session adds ?PHPSESSID vars into html inside a textarea, which
causes hassles when you're using a textarea to store html code in the
db.

perhaps this has been dealt with, and if so, i apologise, but i couldna
find it.

in advance, thankyou




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




Bug #17298 Updated: stristr is not case-insensitive with scandinavian alphabets

2002-05-17 Thread hannu . maksimainen

 ID:   17298
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Strings related
 Operating System: linux 2.4.18
 PHP Version:  4.2.0
 New Comment:

That fixed the problem.

To be more specific, it is enough to write setlocale(LC_CTYPE, fi_FI)
in this case.

LC_CTYPE for character classification and conversion

Thanks.


Previous Comments:


[2002-05-17 18:51:23] [EMAIL PROTECTED]

It's really a locale issue. Not PHP problem in, you just need to set
the locale correctly.

Either via environment var LC_ALL or setting it in the script with
setlocale(), e.g.:

setlocale(LC_ALL, fi_FI);

--Jani




[2002-05-17 18:40:04] [EMAIL PROTECTED]

Mandrake 7.2 with kernel 2.4.18
apache 2.0.35
php 4.2.0

I also tested this with my friend's server and it didn't work there
either. He has Debian Linux (2.4.16 kernel) with apache 1.3.23 and php
4.1.2.



[2002-05-17 18:13:38] [EMAIL PROTECTED]

I can't reproduce this..it might be some locale issue.
Which linux distro?

--Jani




[2002-05-17 18:04:34] [EMAIL PROTECTED]

I have a string There are Ä and ä in scandinavian alphabets.

I want stristr function to return everything after the first occurence
of ä (capital Ä in this case) in my script:

$str = There are Ä and ä in scandinavian alphabets;
echo stristr($str, ä);

It returns ä in scandinavian alphabets.
It should return Ä and ä in scandinavian alphabets.

--
With 'normal' alphabets it works ok. Like this:

$str = There are B and b in scandinavian alphabets;
echo stristr($str, b);

and it returns B and b in scandinavian alphabets




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




Bug #17296: error in http://www.php.net/manual/en/faq.using.php

2002-05-17 Thread spambo

From: [EMAIL PROTECTED]
Operating system: 
PHP version:  4.2.1
PHP Bug Type: Documentation problem
Bug description:  error in http://www.php.net/manual/en/faq.using.php

Please report this as a documentation problem at http://bugs.php.net/
Thanks,
Goba

- Original Message - 
From: Eric Lambart [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, May 03, 2002 2:11 AM
Subject: [PHP-DOC] error in http://www.php.net/manual/en/faq.using.php

 on this page: http://www.php.net/manual/en/faq.using.php
 
 There is an error between items 5 and 6 on this page.  The code sample
 and half of the text for answer #5 are actually from #6.
 
 More specifically:
 
 In #5, following the text The functions header(), set_cookie() and the
 session functions need to add headers to the output stream. Headers can
 only be sent before all other content 
 there is a misplaced period, followed by the text of answer #6 starting
 from the third word.
 
 Have a look, you'll see what I mean.
 
 There is no mention of ob_start() as I presume you folks meant to have
 there.
 
 Hope this helps, thanks for your great work.
 --Eric

-- 
Edit bug report at http://bugs.php.net/?id=17296edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17296r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17296r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17296r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17296r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17296r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17296r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17296r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17296r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17296r=globals




Bug #17299: zlib.output_compression INI change permissions

2002-05-17 Thread bob

From: [EMAIL PROTECTED]
Operating system: RH Linux 7.2
PHP version:  4.2.0
PHP Bug Type: Output Control
Bug description:  zlib.output_compression INI change permissions

The php.ini configuration directive zlib.output_compression is defined as:
 STD_PHP_INI_BOOLEAN(zlib.output_compression, 0, PHP_INI_ALL,
OnUpdate_zlib_output_compression, output_compression, zend_zlib_globals,
zlib_globals)

However, the OnUpdate_zlib_output_compression function does not
enable/disable this functionality. The output compression is only enabled
during request initalization, so having INI_ALL access is confusing when
you cannot enable or disable within a script.

Suggest changing to PHP_INI_SYSTEM to indicate its true nature or better
yet a feature request to move the functionality of RINIT to its own
routine and have RINIT use it, as well as OnChange_zlib_output_compression
after detecting if any output has already been sent.
-- 
Edit bug report at http://bugs.php.net/?id=17299edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17299r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17299r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17299r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17299r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17299r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17299r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17299r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17299r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17299r=globals




Bug #15418 Updated: bzdecompress returning negative numbers instead of strings

2002-05-17 Thread x86zman

 ID:   15418
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Closed
 Bug Type: Bzip2 Related
 Operating System: Linux (2.4.17 ix86)
 PHP Version:  4.1.1
 New Comment:

This bug is _STILL_ alive  exist also on Win32 ,
as i'm getting the same Result (neg. numbers instead of bzip2
compressed output) on Win2K.Srvr (SP2+SRP1) with PHP 4.2.1 (and before
with 4.2  4.1.1  4.1.0) ... now it's reached the report time .,

this should be a tiny glitch somewhere in this extension ,
please fix it !


Previous Comments:


[2002-02-07 06:36:59] [EMAIL PROTECTED]

This is probably fixed in CVS. Reopen if it's not.



[2002-02-06 21:56:17] [EMAIL PROTECTED]

This APPEARS that it may be a re-surgence of bug#12233, 
which was marked closed several months ago...

I am getting bzcompressed strings into a script, which is 
then supposed to bzdecompress them and save the 
bzdecompressed strings to a file.  What's coming out is 
the same sort of thing described in bug#12233 - instead of 
the strings I'm getting -7-5-5-5-5(etc.)

I also tried grabbing the current CVS.  I couldn't get 
./buildconf to work right, but I did try copying the 
current files out of CVS's ext/bz2 directory over the top 
of 4.1.1's released files and recompiling 4.1.1 that way, 
but still no fix...

Example (in the following example, '$fhandle' is an 
fopen'ed URL which is a script that opens a file and sends
it as bzcompressed strings.  THIS script has been tested, 
and works fine - I can use wget to fetch the same data and 
successfully bunzip2 it from the console.  $savehandle is 
the local file that's been fopen'ed to save the 
bzdecompressed data to [and which is getting the 
-7-5-5-5-5 in it...])

while(!feof($fhandle))
{
$data=fread($fhandle,8192);
$outdata=bzdecompress($data);
fwrite($savehandle,$outdata);
}





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




Bug #17300: bzcompress outs negative numbers (err codes ?)

2002-05-17 Thread x86zman

From: [EMAIL PROTECTED]
Operating system: Win32 (W2K.Srvr w/SP2SRP1)
PHP version:  4.2.1
PHP Bug Type: Bzip2 Related
Bug description:  bzcompress outs negative numbers (err codes ?)

bzcompress outs negative numbers (err codes ?) !

no matter whatever data length or type, blocksize or workfactor you may
feed it with , the result is the same -8 ...

i've searched the bug db before reporting and saw that you've marked this
issue closed , and even moreover - that this extension seems problematic
since 4.0.4 (almost since it've ever existed ...) !

could you plz fix ( stabilize ?) this extension at once ?
-- 
Edit bug report at http://bugs.php.net/?id=17300edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17300r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17300r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17300r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17300r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17300r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17300r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17300r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17300r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17300r=globals




Bug #17028 Updated: [chm] bug on language.types.resource.html

2002-05-17 Thread dw59

 ID:   17028
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: Documentation problem
 Operating System: windows
 PHP Version:  4.1.2
 New Comment:

Now I can't do the Edit Submission on the actual bug, it states that
I can't change bug to that state...Did I miss something?

Anyway thanks...where is this newer version?  All I see is the version
5, built March 20th.

Dennis Williams


Previous Comments:


[2002-05-16 14:51:10] [EMAIL PROTECTED]

There is a new version available (built 2002-05-09), in which I don't
get such an error. (Don't have the old version to check it).

Would you please check this new version if the problem still
persisits?

Thomas




[2002-05-06 09:23:01] [EMAIL PROTECTED]

WinME (4.90.3000) + IE 5.5 (128-bit Cipher Strength)

Thanks,
Dennis Williams



[2002-05-06 04:07:55] [EMAIL PROTECTED]

Strange. I still cannot reproduce any of these bugs with IE6 + Winxp
and IE5 + Win2k. What Win OS do you have?

Goba



[2002-05-06 01:06:31] [EMAIL PROTECTED]

I have found a bug on page language.types.resource.html
[chm date: 2002-04-20]...

I don't know if this is exactly a bug...it seems to do with IE 5.5 and
script debugging.  (I do have Microsoft Script Debugger installed on my
system.)  Even though I have script debugging turned off (and continue
flag set to true when scripting errors encountered) I still get this
pop-up on most pages in the .chm format help file:

Internet Explorer Script Error

An error has occurred in the script on this page.

Line:  3
Char:  25
Error:  'document.all.unotes' is null or not an object
Code:  0
URL:  ...

Do you want to continue running scripts on this page? Yes|No

Line number, character number and error message seem to remain constant
on all pages where this occurs.

Thanks,
Dennis Williams







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




Bug #17262 Updated: PHP 4.2.1 fails to install when compiled as a CGI

2002-05-17 Thread jeroen

 ID:   17262
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Feedback
 Bug Type: *Compile Issues
 Operating System: RedHat linux 7.3
 PHP Version:  4.2.1
 New Comment:

I'm experiencing the same bug on my Mandrake 8.1 system, except I'm
trying to compile it as a Apache2 Shared Module. I added an empty dir
called libs in the dir where I unpacked PHP 4.2.1 and it suddenly
worked, thanks to Daniel. :)


Previous Comments:


[2002-05-16 17:00:00] [EMAIL PROTECTED]

I think it´s my Bug ID 17203, so manually creating the directory libs
may be the solution.

Daniel



[2002-05-16 09:00:54] [EMAIL PROTECTED]

This is the full error,  I can paste the entire contents of the make
install when I get to work if you like.



[2002-05-16 06:41:20] [EMAIL PROTECTED]

Can you please copy and paste the FULL error?



[2002-05-15 18:20:04] [EMAIL PROTECTED]

When compiling php with the following options on a stock RedHat 7.3
system:

./configure \
--without-mysql \
--with-config-file-path=/etc \
--with-zlib \
--with-gd \
--with-pgsql \
--with-system-regex \
--with-pdflib

I recieve this error when performing the make install:

Making install in .
make[1]: Entering directory `/sources/php-4.2.1'
make[1]: *** [install-sapi] Error 1
make[1]: Leaving directory `/sources/php-4.2.1'
make: *** [install-recursive] Error 1

The php binary is not installed when I get this message.  I can copy
the file into the /usr/local/lib directory and it *appears* to work ok.
 This problem was not present in php version 4.1.2.




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




Bug #17301: Uhh.. just read the description

2002-05-17 Thread shilo27560

From: [EMAIL PROTECTED]
Operating system: Windows 98
PHP version:  4.2.1
PHP Bug Type: Variables related
Bug description:  Uhh.. just read the description

I have recently upgraded to php version 4.2.1 and before that everything
was working fine, but now evertime i use a variable which is defined by
user input on a seperate html form or gets its value from a query string
it get this error:

Notice: Undefined variable: room in c:\program
files\apache\apache\htdocs\php\index.php on line 10

Notice: Undefined variable: room in c:\program
files\apache\apache\htdocs\php\index.php on line 11


even though i reach it like this, http://aptiva/php/index.php?room=Aptiva
it still comes out with the same error

If you are still unclear what i am trying to say (im not the best at
explaining things) then check out the below exapmle of a code that would
give me this error:

I would type in the url for this script while including the query string
of ?username=hipassword=hito
which would leed to this script,

?
echo
The username is ? echo $username; ?
The Password is ? echo $password; ?

?

and i would get the error of :

Notice: Undefined variable: username in c:\program
files\apache\apache\htdocs\php\index.php on line 3

Notice: Undefined variable: password in c:\program
files\apache\apache\htdocs\php\index.php on line 4

Can anyone help me here?

PS. i am a twelve year old so be descriptive
also i am using apache as my server software
-- 
Edit bug report at http://bugs.php.net/?id=17301edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17301r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17301r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17301r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17301r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17301r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17301r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17301r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17301r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17301r=globals




Bug #17301 Updated: Uhh.. just read the description

2002-05-17 Thread jimw

 ID:   17301
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: Variables related
 Operating System: Windows 98
 PHP Version:  4.2.1
 New Comment:

In PHP 4.2.0, the 'register_globals' setting default changed to
be off. See http://www.php.net/release_4_2_0.php for more info.
We are sorry about the inconvenience, but this change was a necessary
part of our efforts to make PHP scripting more secure and portable.


Previous Comments:


[2002-05-17 22:05:53] [EMAIL PROTECTED]

I have recently upgraded to php version 4.2.1 and before that
everything was working fine, but now evertime i use a variable which is
defined by user input on a seperate html form or gets its value from a
query string it get this error:

Notice: Undefined variable: room in c:\program
files\apache\apache\htdocs\php\index.php on line 10

Notice: Undefined variable: room in c:\program
files\apache\apache\htdocs\php\index.php on line 11


even though i reach it like this,
http://aptiva/php/index.php?room=Aptiva
it still comes out with the same error

If you are still unclear what i am trying to say (im not the best at
explaining things) then check out the below exapmle of a code that
would give me this error:

I would type in the url for this script while including the query
string of ?username=hipassword=hito
which would leed to this script,

?
echo
The username is ? echo $username; ?
The Password is ? echo $password; ?

?

and i would get the error of :

Notice: Undefined variable: username in c:\program
files\apache\apache\htdocs\php\index.php on line 3

Notice: Undefined variable: password in c:\program
files\apache\apache\htdocs\php\index.php on line 4

Can anyone help me here?

PS. i am a twelve year old so be descriptive
also i am using apache as my server software




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




Bug #17302: can't pass result sets between functions

2002-05-17 Thread sunmiewon

From: [EMAIL PROTECTED]
Operating system: W2K
PHP version:  4.2.1
PHP Bug Type: MSSQL related
Bug description:  can't pass result sets between functions

Using PHP 4.2.1 on Apache in W2K, connecting to MSSQL7 also on W2K. The db
connection seems to work fine and I get data returned. The problem is when
I try to split the data retrieval in one function, and then pass the
result set back to another script. No data gets returned and my script
hangs for a while. If I run the retrieval in-line with the display script,
things are fine.

//* Does work *//
   $conn = db_connect_user();
   if ($conn==false)
  return false;
   $result = mssql_query(select id, name, db_name
 from rm_company, $conn);
//Loop through and gather the info about the orders for this customer
$count  = mssql_num_rows($result);
for($i = 0; $i  $count; $i++) {
$company_list[$i][0]=mssql_result($result,$i,0);
$company_list[$i][1]=mssql_result($result,$i,1);
$company_list[$i][2]=mssql_result($result,$i,2);
}
if(!($company_list==false))
{
$list_count = count($company_list);
// etc.
**
//*Does not work*//
..top of script..
$company_list = get_company_list();
if(!($company_list==false))
{
$list_count = count($company_list);

..further down script/in another script (have tried both)..

function get_company_db()
{   $conn = db_connect_user();
   if ($conn==false)
  return false;
   $result = mssql_query(select id, name, db_name
 from rm_company, $conn);
if (!$result)
  return false;  // not found
else if (mssql_num_rows($result)==0)
  return false; // no orders found
else
{
//Loop through and gather the info about the orders for this
customer
{
$count  = mssql_num_rows($result);
for($i = 0; $i  $count; $i++) {
$company_list[$i][0]=mssql_result($result,$i,0);
$company_list[$i][1]=mssql_result($result,$i,1);
$company_list[$i][2]=mssql_result($result,$i,2);
}
}
return $company_list;
}
}
-- 
Edit bug report at http://bugs.php.net/?id=17302edit=1
-- 
Fixed in CVS:http://bugs.php.net/fix.php?id=17302r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=17302r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=17302r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17302r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17302r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17302r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=17302r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=17302r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=17302r=globals




Bug #14702 Updated: segfault in OCIFetchStatement with 1 or 2 chars CLOB

2002-05-17 Thread php-bugs

 ID:   14702
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   No Feedback
 Bug Type: OCI8 related
 Operating System: Linux 2.4
 PHP Version:  4.1.0
 New Comment:

No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.


Previous Comments:


[2002-04-13 09:03:48] [EMAIL PROTECTED]

please send me a short selfcontained testcase for this




[2001-12-27 07:55:59] [EMAIL PROTECTED]

(gdb) bt
#0  0x4056bc67 in ttci2u () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#1  0x40335490 in kpulbcr () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#2  0x40579002 in ttcdrv () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#3  0x40448855 in nioqwa () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#4  0x4035a9f2 in upirtrc () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#5  0x4033742d in kpurcsc () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#6  0x4032500c in kpulfrd () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#7  0x40344d7a in OCILobRead () from
/opt/oracle/Oracle8iR3/lib/libclntsh.so.8.0
#8  0x80781c6 in oci_loadlob (connection=0x81d7d0c, mydescr=0x81d7c24,
buffer=0xbfffd9b8, loblen=0xbfffd9bc)
at oci8.c:1860
#9  0x80771f4 in _oci_make_zval (value=0x81f206c, statement=0x81db77c,
column=0x81e641c, 
func=0x811d5ef OCIFetchStatement, mode=8) at oci8.c:1242
#10 0x807bbc6 in zif_ocifetchstatement (ht=2, return_value=0x81e65e4,
this_ptr=0x0, return_value_used=1) at oci8.c:3970
#11 0x8103a55 in execute (op_array=0x81d15e4) at
/home/ch/php-4.1.0/Zend/zend_execute.c:1590
#12 0x80e5cc2 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:814
#13 0x8063921 in php_execute_script (primary_file=0xb9d0) at
main.c:1309
#14 0x8061bc4 in main (argc=2, argv=0xba74) at cgi_main.c:738
#15 0x407faf31 in __libc_start_main (main=0x80613d4 main, argc=2,
ubp_av=0xba74, init=0x805f8d0 _init, 
fini=0x811843c _fini, rtld_fini=0x4000e274 _dl_fini,
stack_end=0xba6c) at ../sysdeps/generic/libc-start.c:129



[2001-12-27 05:52:55] [EMAIL PROTECTED]

Can you provide a backtrace?
(http://bugs.php.net/bugs-generating-backtrace.php)



[2001-12-26 13:28:59] [EMAIL PROTECTED]

php segfault with the following code :

$stmt = OCIParse($conn,select myclob from I18N);
OCIExecute($stmt);
OCIFetchStatement($stmt,$results);

when myclob contains at least one row with one or two characters. work
fine when clob length = 0 or = 3.
oracle and php use utf-8.

php : 4.1.0 and 4.0.6 on linux x86
oracle : 8.1.7.2 on sparc64





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