[PHP-DEV] PHP 4.0 Bug #10238: erealloc() function error

2001-04-09 Thread csjang

From: [EMAIL PROTECTED]
Operating system: WINDOWS 98
PHP version:  4.0.4pl1
PHP Bug Type: Filesystem function related
Bug description:  erealloc() function error

I found tht folloing error during file ( file size ablout 12 MB) uploading :

[Mon Apr 09 15:33:22 2001] [error] [client 127.0.0.1] Premature end of script headers: 
c:/php/php.exe
[Mon Apr 09 15:33:22 2001] [error] [client 127.0.0.1] FATAL:  erealloc():  Unable to 
allocate 5876001 bytes

Maybe above error is some PHP memory error. I can't solve
this problem.

PLEASE HELP ME.


-- 
Edit Bug report at: http://bugs.php.net/?id=10238edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Latest CVS crashes on Win32

2001-04-09 Thread Sebastian Bergmann

  Latest CVS crashes - built as CGI - on Win32.

-- 
 sebastian bergmann[EMAIL PROTECTED]
   http://www.sebastian-bergmann.de

 bonn.phpug.de | www.php.net | www.phpOpenTracker.de | www.titanchat.de

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10233 Updated: Big file uploading problem form HTML FORM

2001-04-09 Thread derick

ID: 10233
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Duplicate
Bug Type: Apache related
Assigned To: 
Comments:

Duplicate of #10238

Previous Comments:
---

[2001-04-08 22:04:09] [EMAIL PROTECTED]
REPLY to derick

I have considered your comments that my script took more than 8MB of memory. But the 
same problem occurred.
Exact error message from IE5.0 is "Can not display this page". I think FORM HTML 
problem. What can I do ?


ID: 10233
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: Apache related
Assigned To: 
Comments:

I don't think this is a bug, but that your script took more than 8MB of memory. Can 
you try changing your memory limit to a higher value?

Previous Comments:
---

[2001-04-08 07:11:16] [EMAIL PROTECTED]
I try file uploading using Apache + PHP under WINDOW ME.
I have set the my php.ini as following :

;;;
; Resource Limits ;
;;;
PHPRC=C:/WINDOWS  
max_execution_time = 600 ; Maximum execution time of each script, in seconds
memory_limit = 8M

post_max_size   =   100M


; File Uploads ;

file_uploads= On; Whether to allow HTTP file uploads
upload_tmp_dir  = D:/temp
upload_max_filesize = 100M

I could upload file sized 5.96 MB but could not upload 
above filesize,5.96 MB.
Maybe this is bug.
Please e-mail to me with solutions.

Good luck to you.


---

[2001-04-08 07:26:03] [EMAIL PROTECTED]
I don't think this is a bug, but that your script took more than 8MB of memory. Can 
you try changing your memory limit to a higher value?

---

[2001-04-08 07:11:16] [EMAIL PROTECTED]
I try file uploading using Apache + PHP under WINDOW ME.
I have set the my php.ini as following :

;;;
; Resource Limits ;
;;;
PHPRC=C:/WINDOWS  
max_execution_time = 600 ; Maximum execution time of each script, in seconds
memory_limit = 8M

post_max_size   =   100M


; File Uploads ;

file_uploads= On; Whether to allow HTTP file uploads
upload_tmp_dir  = D:/temp
upload_max_filesize = 100M

I could upload file sized 5.96 MB but could not upload 
above filesize,5.96 MB.
Maybe this is bug.
Please e-mail to me with solutions.

Good luck to you.

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10233edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #9857 Updated: define(named_constant)

2001-04-09 Thread shmengie_2000

ID: 9857
User Update by: [EMAIL PROTECTED]
Old-Status: Open
Status: Closed
Bug Type: IIS related
Description: define("named_constant")

Making this change in oci8.c

#ifdef ZTS 
#define PHP_OCI_INIT_MODE OCI_DEFAULT 
/* OCI_DEFAULT was OCI_THREADED on the above line*/
#else
#define PHP_OCI_INIT_MODE OCI_DEFAULT
#endif

Now the defined() does not have a problem.  This makes me reasonably sure that it is 
OCI8 walking on other memory.  By changing OCI_THREADED to OCI_DEFAULT oci does not 
use it's own memory sharing features in threaded environments.  

This removes any benifit that may be gained by a threaded environment, but also cause 
PHP not to crash.  I find the PHP not crashing much more productive.  ;-)

Will have to work on OCI source to take advantage of threaded environments.  Think it 
will be a major re-write of OCI8.c for this, because other attemts of a quick source 
fix have been unsuccessful. 

For now, this works.

joebrown
podiatryfl.com

Previous Comments:
---

[2001-04-07 17:29:17] [EMAIL PROTECTED]
User feedback:
--

I'm using the latest snapshot's on win32.

Getting some needed practice with MSVC...

I think the problem is that OCI is walking on TSRM
local storage.  I haven't been able to verify it, but
my gut says it's so.


---

[2001-04-06 23:57:54] [EMAIL PROTECTED]
Are you using PHP 4.0.1? If so, could you please try 
with the latest release, 4.0.4pl1?

--Jani


---

[2001-03-29 01:34:23] [EMAIL PROTECTED]
Taking a shot in the dark, hoping this bug comes to sombody who "knows" attention.

Prior comments are somewhat misleading.  I'm using OCI8, and also Manuel Lemos' 
Metabase.

Parusing through the source, I've noticed that there are some constants defined for 
OCI8 (which are documented):
eg:
REGISTER_LONG_CONSTANT("OCI_DEFAULT",OCI_DEFAULT, CONST_CS | CONST_PERSISTENT);

I question this CONST_PERSISTENT value.  Is it possible that the persistence is 
helping non persistent constants (in the php code) strattle the void between pages?

BTW: what does _zval_dtor in the source mean? Specifically, "dtor"

---

[2001-03-26 17:46:42] [EMAIL PROTECTED]
A define on php4isapi has a tendency to bleed over to the next page load.  refresh and 
a completely different page have retain a defined constant.

eg:
test1.php
?
define("anything",1);
echo (defined("anything")?"anything defined":"anything not defined");
?

test2.php
echo (defined("anything")?"anything defined":"anything not defined");

after pointing browser at test1.php
test 2.php contains "anything defined", instead of "not"

---

[2001-03-20 01:15:49] [EMAIL PROTECTED]
With this code at the top of an include file, the results are unpretictable.

if(!defined("METABASE_MYSQL_INCLUDED"))
{
 define("METABASE_MYSQL_INCLUDED",1);
 ...rest of include file...
}

require_once(); seems to work though.


---

The remainder of the comments for this report are too long.  To view the rest of the 
comments, please view the bug report online.

Full Bug description available at: http://bugs.php.net/?id=9857


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Request for new feature: $HTTP_SESSION_VARS whenregister_globals = on

2001-04-09 Thread Carsten Gehling

From: "Alexander Feldman" [EMAIL PROTECTED]
Sent: Friday, April 06, 2001 10:46 PM


 Hm, very strange. You are absolutely right - I do not see any problems as
 well. Not only with the current cvs but with the older phps also... But I
 am sure I have seen some time ago exactly what was described by Carsten
 Gehling. Maybe it is kind of group hallucination ;)

Try this:

===
?php
session_start();

session_register("c");

$HTTP_SESSION_VARS["c"] = $HTTP_SESSION_VARS["c"] + 1;

var_dump($HTTP_SESSION_VARS);
?

===

And try reloading the page a couple of times. With register_globals = Off,
the session variable "c" will be incrementing by one on each reload. With
register_globals = On, it will always be 1 (thereby showing, that it does
not exist when reloading).

- Carsten



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] PHP 4.0 Bug #10225 Updated: I have

2001-04-09 Thread Carsten Gehling

From: [EMAIL PROTECTED]
Sent: Saturday, April 07, 2001 7:58 PM
Subject: [PHP-DEV] PHP 4.0 Bug #10225 Updated: I have


 I had installed Oracle 8i(8.16) Client For win2000.
 And I modify the C:\winnt\php.ini to

 extension=php_oci8.dll
 ;extension=php_openssl.dll
 extension=php_oracle.dll

 When I restart the IIS, it show the message
 "Unable to load dynamic library 'c:\php\extensions\php_oracle.dll' - "

Have you set the following line in php.ini:

extension_dir = ./extensions

it is default set to

extension_dir = .

- Carsten



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] /ext/oci8/oci8.c win32 bugfix.

2001-04-09 Thread Joe Brown

If someone would apply this patch to ext/oci8/oci8.c I think the Oracle
using Win32 community would be greatful.

Don't know if all threaded environments have a problem with OCI8's behaviour
in threaded mode.  PHP on win32 really doesn't like it...  I haven't been
able to get it to crash with this modification.  W/out this modification I
haven't been able to keep it from crashing.

This change only affects builds on Win32, making OCI8 behave like it does on
traditional Unix.  If possible, please include in the next RC or final
release of 4.0.6

Thanks,
joebrown
podiatryfl.com

--- php4/ext/oci8/oci8.c  Fri Mar 02 04:45:08 2001
+++ php4/ext/oci8/oci8.c  Mon Apr 09 03:33:10 2001
@@ -342,7 +342,7 @@
 {
zend_class_entry oci_lob_class_entry;

-#ifdef ZTS
+#if ZTS  !WIN32
 #define PHP_OCI_INIT_MODE OCI_THREADED
 #else
 #define PHP_OCI_INIT_MODE OCI_DEFAULT



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10195 Updated: https takes forever and a day to return when php is loaded in Apache

2001-04-09 Thread Clement . Ong

ID: 10195
User Update by: [EMAIL PROTECTED]
Old-Status: Feedback
Status: Open
Bug Type: OpenSSL related
Description: https takes forever and a day to return when php is loaded in Apache

I tried building with the lastest build as suggested by you and the build errored when 
it came to making sapi/cgi.

I compared the MakeFile in the sapi directory between php 4.02 and the latest and they 
are different with the lastest one making reference to CGI in several places.

Also 4.02 has a Makefile in sapi/cgi whereas the latest doesn't.

Also what version of curl are you using I'm using 7.7.1.



Previous Comments:
---

[2001-04-06 11:30:28] [EMAIL PROTECTED]
Works for me just fine with latest RC of PHP 4.0.5 and latest CVS. And I have the same 
versions of openssl and mod_ssl and I have Curl enabled.

Please try the latest snapshot: http://snaps.php.net/

--Jani



---

[2001-04-06 00:48:50] [EMAIL PROTECTED]
Latest information. If I remove with-curl out from the configuration and rebuild PHP 
the problem no longer appears.

I need the curl functionality to use https within the PHP script to another secure web 
server.



---

[2001-04-05 21:07:52] [EMAIL PROTECTED]
I am running Apache 3.1.19 with mod_ssl-2.8.2-1.3.19 and OpenSSl-0.9.6 for SSL 
functionality.

Using https from my Internet Explorer 5.0 browser causes the requested web page to be 
returned after a very long wait, .eg more than 20 minutes maybe longer. Subsequent 
retrieval takes as long too.

If I have PHP disabled by removing the LoadModule and AddModule directive https works 
immediately however when I reinstate the PHP modules I would experience the problem 
again.

Other scenario :-

  1. retrieved a https page with my browser without PHP(response received 
immediately)
  2. modify httpd.conf to enable PHP
  3. restarts Apache 
  4. starts a *NEW* browser to retrieve https(waits very long)
  5. using the same browser session in step 1 to retrieve
 again using https(response received immediately)

Also noticed in the Apache errors_log file the following error :-

[FriApr 6   11:46:302001]   [notice]child   pid 2654   
 exitsignal  Segmentationfault   (11)
[FriApr 6   11:46:362001]   [notice]child   pid 2668   
 exitsignal  Segmentationfault   (11)
[FriApr 6   11:46:362001]   [notice]child   pid 2667   
 exitsignal  Segmentationfault   (11)


This is how I configure PHP :-

./configure --with-apxs=/usr/local/apache/bin/apxs 
--with-config-file-path=/etc/php 
--with-mysql=/usr 
--with-java=/usr/java/jdk1.3 
--with-ldap 
--with-imap 
--with-curl 
--with-gd 
--enable-versioning


  



---


Full Bug description available at: http://bugs.php.net/?id=10195


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10238 Updated: erealloc() function error

2001-04-09 Thread hholzgra

ID: 10238
Updated by: hholzgra
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Analyzed
Old-Bug Type: Filesystem function related
Bug Type: Feature/Change Request
Assigned To: 
Comments:

current implementation of file uploads
requires the uploaded form data including 
the file data itself to be completly held
in memory for a short while

if your file gets to big it may exhaust 
the available memory on your system

to prevent php from bailing out here you
should set a lower limit for upload_max_filesize 
in PHP init and/or switch to an operating system
with better memory handling capabilities than
the still somehow DOS-based Win95/98 line

PS: moved to change request as there should be
a more clever way to deal with post data than
to stuff it all into main memory ... i think i
remember Rasmus talking about someone working on 
this when we met in Brussels

Previous Comments:
---

[2001-04-09 02:41:58] [EMAIL PROTECTED]
I found tht folloing error during file ( file size ablout 12 MB) uploading :

[Mon Apr 09 15:33:22 2001] [error] [client 127.0.0.1] Premature end of script headers: 
c:/php/php.exe
[Mon Apr 09 15:33:22 2001] [error] [client 127.0.0.1] FATAL:  erealloc():  Unable to 
allocate 5876001 bytes

Maybe above error is some PHP memory error. I can't solve
this problem.

PLEASE HELP ME.

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10238edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Request for new feature: $HTTP_SESSION_VARS whenregister_globals = on

2001-04-09 Thread Carsten Gehling

From: "Carsten Gehling" [EMAIL PROTECTED]
Sent: Monday, April 09, 2001 9:31 AM
Subject: Re: [PHP-DEV] Request for new feature: $HTTP_SESSION_VARS
whenregister_globals = on


 From: "Alexander Feldman" [EMAIL PROTECTED]
 Sent: Friday, April 06, 2001 10:46 PM

  Hm, very strange. You are absolutely right - I do not see any problems
as
  well. Not only with the current cvs but with the older phps also... But
I
  am sure I have seen some time ago exactly what was described by Carsten
  Gehling. Maybe it is kind of group hallucination ;)

 Try this:

snip

Or this, which is slightly more interesting:


?php
session_start();
session_register("c");
echo "#".SID."#br";
$HTTP_SESSION_VARS["c"] = $HTTP_SESSION_VARS["c"] + 1;
var_dump($HTTP_SESSION_VARS);
?



On the first run, SID is displayed in the browser, but when reloading the
page, SID is empty.

As a side note: I run PHP 4.0.4pl1 as CGI on Win2k IIS5.

- Carsten



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10237 Updated: sybase_query returns 1 instead of link id with action queries

2001-04-09 Thread joey

ID: 10237
Updated by: joey
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Closed
Bug Type: Sybase-ct (ctlib) related
Assigned To: 
Comments:

Link ID is returned by sybase_connect, not sybase_query.
In your example, use:
echo sybase_affected_rows($con);

A close examination of the PHP Manual will solve this kind
of confusion.

Not a bug.

Previous Comments:
---

[2001-04-09 02:01:54] [EMAIL PROTECTED]
sybase_query returns 1 instead of a link id when I run an action query. The following 
code reproduces the error:

$con = sybase_connect("SYBASE", "user", "pass");
sybase_select_db("cope");
$qry = sybase_query("update ...", $con);

echo sybase_affected_rows($qry);
sybase_close($con);

The update query works in isql.

Here is my configure line:
'./configure' '--with-apache=../apache_1.3.19' '--with-sybase-ct=/opt/sybase' 
'--with-curl=../curl-7.7' '--with-mm=../mm-1.1.3' '--enable-bcmath' 
'--enable-calendar' '--enable-ctype' '--enable-exif' '--enable-ftp' 
'--enable-gd-imgstrttf' '--with-gd' '--enable-trans-sid' '--enable-shmop' 
'--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-wddx'

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10237edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10239: file MSVCIRT.DLL connected to missing export MSVCRT.DLL: ??_U@YAPAXI@Z

2001-04-09 Thread jozokozak

From: [EMAIL PROTECTED]
Operating system: Win 95, Apache 1.3.
PHP version:  4.0.0
PHP Bug Type: *Install and Config
Bug description:  file MSVCIRT.DLL connected to missing export MSVCRT.DLL: 
??_U@YAPAXI@Z

I am trying to run php 4 on Win 95 under Apache 
when I use IE4 to run http://mywebserver/index.php it gives error: "file MSVCIRT.DLL 
connected to missing export MSVCRT.DLL: ??_U@YAPAXI@Z", those are files of microsoft 
runtime library. 


-- 
Edit Bug report at: http://bugs.php.net/?id=10239edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10204 Updated: fgets causes memory leaks

2001-04-09 Thread pallmall

ID: 10204
User Update by: [EMAIL PROTECTED]
Old-Status: Feedback
Status: Open
Bug Type: Sockets related
Description: fgets causes memory leaks

 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

Previous Comments:
---

[2001-04-06 09:19:49] [EMAIL PROTECTED]
Um, yes, the memory usage increases because you are appending an infinite number of 
copies of the google page to your $page variable.

I can't see any leak in PHP - no leaks are reported by the memory manager.

Can you give me more information about how the memory usage increases, and what you 
would expect it to be?

Could you try explicitly fclose()ing your $fps too - you might find it useful in 
reducing memory cost.

--Wez.

---

[2001-04-06 08:54:33] [EMAIL PROTECTED]
I noticed this last night in the socket code: it uses a simple read-buffering scheme 
where the read buffer will only grow, so we are effectively storing the everything we 
have read in memory.

However, I would expect the behaviour to be the same with fread.

I take it the memory usage returns to normal once the page has completed?

--Wez.

---

[2001-04-06 07:54:22] [EMAIL PROTECTED]
Try this script (tested on windows, linux and open BSD(:

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fgets($fp, 1000);
  }
}
?

Run it with top or whatever running and watch the memory usage go up and up (not 
especially quickly because the page is small, but in certain situations I've had 
memory chewage of 1mb/minute).

Now cf.

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fread($fp, 1000);
  }
}
?

Memory usage remains constant here.

[This meant I had to rewrite the readLine method in Net_Socket to use fread instead of 
fgets.]

---


Full Bug description available at: http://bugs.php.net/?id=10204


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Sascha Schumann

 4. The CGI version of PHP is always built and installed.

I think this should be optional.

- Sascha Experience IRCG
  http://schumann.cx/http://schumann.cx/ircg


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread James Moore


  4. The CGI version of PHP is always built and installed.
 
 I think this should be optional.

Perhaps optionally disabled.. --without-cgi?

James

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV]--with-pear[=DIR] patch

2001-04-09 Thread Derick Rethans

On Mon, 9 Apr 2001, James Moore wrote:


   4. The CGI version of PHP is always built and installed.
 
  I think this should be optional.

 Perhaps optionally disabled.. --without-cgi?

I would go for optionally on, I really dont want to build both the apache
module (p.e.) AND the CGi at the same time. For QA testing this is fine,
but not for production servers.

Derick Rethans

-
PHP: Scripting the Web - www.php.net - [EMAIL PROTECTED]
 SRM: Site Resource Manager - www.vl-srm.net
-


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV]--with-pear[=DIR] patch

2001-04-09 Thread Sascha Schumann

On Mon, 9 Apr 2001, James Moore wrote:


   4. The CGI version of PHP is always built and installed.
 
  I think this should be optional.

 Perhaps optionally disabled.. --without-cgi?

First, it is a boolean feature, hence enable/disable would be
correct.  Second, defaulting to the behaviour of prior
releases is IMHO the best option for minor releases.  If we
decide that it is indeed a useful feature, we can enable it
by default in 4.1.x (or whatever comes next).

- Sascha Experience IRCG
  http://schumann.cx/http://schumann.cx/ircg


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Anil Madhavapeddy

Derick Rethans wrote:

 I would go for optionally on, I really dont want to build both
 the apache module (p.e.) AND the CGi at the same time.
 For QA testing this is fine, but not for production servers.

Well, it really beats the alternative, which is to compile everything
twice ... what's wrong with having a PHP cgi sitting around on a
production server by the way?  It's very handy when trying to debug
stuff, and doesn't intrude on any normal processes either.

Anil


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10204 Updated: fgets causes memory leaks

2001-04-09 Thread pallmall

ID: 10204
User Update by: [EMAIL PROTECTED]
Status: Open
Bug Type: Sockets related
Description: fgets causes memory leaks

 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

Previous Comments:
---

[2001-04-09 06:58:37] [EMAIL PROTECTED]
 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

---

[2001-04-06 09:19:49] [EMAIL PROTECTED]
Um, yes, the memory usage increases because you are appending an infinite number of 
copies of the google page to your $page variable.

I can't see any leak in PHP - no leaks are reported by the memory manager.

Can you give me more information about how the memory usage increases, and what you 
would expect it to be?

Could you try explicitly fclose()ing your $fps too - you might find it useful in 
reducing memory cost.

--Wez.

---

[2001-04-06 08:54:33] [EMAIL PROTECTED]
I noticed this last night in the socket code: it uses a simple read-buffering scheme 
where the read buffer will only grow, so we are effectively storing the everything we 
have read in memory.

However, I would expect the behaviour to be the same with fread.

I take it the memory usage returns to normal once the page has completed?

--Wez.

---

[2001-04-06 07:54:22] [EMAIL PROTECTED]
Try this script (tested on windows, linux and open BSD(:

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fgets($fp, 1000);
  }
}
?

Run it with top or whatever running and watch the memory usage go up and up (not 
especially quickly because the page is small, but in certain situations I've had 
memory chewage of 1mb/minute).

Now cf.

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fread($fp, 1000);
  }
}
?

Memory usage remains constant here.

[This meant I had to rewrite the readLine method in Net_Socket to use fread instead of 
fgets.]

---


Full Bug description available at: http://bugs.php.net/?id=10204


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV]--with-pear[=DIR] patch

2001-04-09 Thread Sascha Schumann

On Mon, 9 Apr 2001, Anil Madhavapeddy wrote:

 Derick Rethans wrote:
 
  I would go for optionally on, I really dont want to build both
  the apache module (p.e.) AND the CGi at the same time.
  For QA testing this is fine, but not for production servers.

 Well, it really beats the alternative, which is to compile everything
 twice

No.  The alternative is to pass --enable-cgi on the command-line.

 ... what's wrong with having a PHP cgi sitting around on a
 production server by the way?  It's very handy when trying to debug
 stuff, and doesn't intrude on any normal processes either.

If the administrator installs it unknowingly, the CGI might
get installed with inproper permissions which lead to
potential security problems.  I respect the wishes of the QA
team, but please don't force your will upon all PHP users in
exchange for a bit of convenience.

- Sascha Experience IRCG
  http://schumann.cx/http://schumann.cx/ircg


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10204 Updated: fgets causes memory leaks

2001-04-09 Thread wez

ID: 10204
Updated by: wez
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: Sockets related
Assigned To: 
Comments:

Sorry - I somehow missed the unset.

However, unset just removes the variable from the symbol table - try using $page = 
null instead.

I am in the process of working on a file abstraction for this stuff, so it will be 
rewritten.

The wierd thing is that I really can't see why fgets would behave differently from 
fread.  Maybe I haven't looked hard enough.

Please let me know if $page = null works around the problem for now.

Previous Comments:
---

[2001-04-09 07:29:57] [EMAIL PROTECTED]
 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

---

[2001-04-09 06:58:37] [EMAIL PROTECTED]
 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

---

[2001-04-06 09:19:49] [EMAIL PROTECTED]
Um, yes, the memory usage increases because you are appending an infinite number of 
copies of the google page to your $page variable.

I can't see any leak in PHP - no leaks are reported by the memory manager.

Can you give me more information about how the memory usage increases, and what you 
would expect it to be?

Could you try explicitly fclose()ing your $fps too - you might find it useful in 
reducing memory cost.

--Wez.

---

[2001-04-06 08:54:33] [EMAIL PROTECTED]
I noticed this last night in the socket code: it uses a simple read-buffering scheme 
where the read buffer will only grow, so we are effectively storing the everything we 
have read in memory.

However, I would expect the behaviour to be the same with fread.

I take it the memory usage returns to normal once the page has completed?

--Wez.

---

[2001-04-06 07:54:22] [EMAIL PROTECTED]
Try this script (tested on windows, linux and open BSD(:

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fgets($fp, 1000);
  }
}
?

Run it with top or whatever running and watch the memory usage go up and up (not 
especially quickly because the page is small, but in certain situations I've had 
memory chewage of 1mb/minute).

Now cf.

?php
set_time_limit(0);
while (1) {
  unset($page);
  print "iteration ". ++$c;
  $fp = fsockopen("google.com", 80);
  fwrite($fp, "GET / HTTP/1.0rnrn");
  while (!feof($fp)) {
$page .= fread($fp, 1000);
  }
}
?

Memory usage remains constant here.

[This meant I had to rewrite the readLine method in Net_Socket to use fread instead of 
fgets.]

---

The remainder of the comments for this report are too long.  To view the rest of the 
comments, please view the bug report online.


ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10204edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #9418 Updated: Upload image file is broken

2001-04-09 Thread sniper

ID: 9418
Updated by: sniper
Reported By: [EMAIL PROTECTED]
Old-Status: Feedback
Status: Closed
Bug Type: *General Issues
Assigned To: 
Comments:

Feedback:
-

Hey, i solve problem. On catalog with php upload script i set
directive:
CharsetDisable on
Now - all ok.

---

This was with Apache which had mod_charset included. 
(Russian)

Just wondering why adding --with-mod_charset doesn't do anything?


--Jani


Previous Comments:
---

[2001-04-03 10:01:09] [EMAIL PROTECTED]
Please try latest snapshot from http://snaps.php.net/
If problem still persists, please send me the original
and uploaded (via form) images to [EMAIL PROTECTED]

--Jani


---

[2001-03-27 04:49:16] [EMAIL PROTECTED]
Hi! I trying snapshot from 22-Mar-2001 - but this not help me. May be in new stable 
release problem with images will be solved?

---

[2001-03-04 22:40:43] [EMAIL PROTECTED]
I make this experiment: 
1) upload image via php. Uploaded image not visible.
2) upload image via ftp (binary) mode. This image is normal visible. 
After that i compare both image with cmp command. Cmp say, what images different.
I can send you my image for probe. 
May be i must try download cvs from snaps.php.net (early i download it from 
cvs.php.net). May be cvs snapshot on this sites different?

---

[2001-03-03 19:17:01] [EMAIL PROTECTED]
I can not reproduce this. Are you sure you're comparing the right images??
Are the uploaded images displayed at all?

--Jani


---

[2001-03-01 21:43:22] [EMAIL PROTECTED]
Yes, 23 feb i download cvs snapshot from cvs.php.net
make 
make install
but this not help me :(...

---

The remainder of the comments for this report are too long.  To view the rest of the 
comments, please view the bug report online.


ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=9418edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] PHP 4.0 Bug #9383 Updated: mcrypt 2.4.9 function causesApache to segfault (fwd)

2001-04-09 Thread Derick Rethans

On Mon, 5 Mar 2001 11:22:23 +0100 (CET) Derick Rethans [EMAIL PROTECTED] wrote:

 Hello Nikos,
 I'm one of the maintainers of the libmcrypt extension for PHP, and there
 are a lot of bugs reported on this lately. SOme of them are the
 extension, but I also think that some are in libmcrypt (as the that is
 forwarded). I think it would be wise if we can elaborate together and fix
 these bugs.
I've just checked libmcrypt on Openbsd ( I do not have any freebsd machines here) and
it seems to work as it should.

 Regards,
 Derick Rethans

-- 
Nikos Mavroyanopoulos


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] session help

2001-04-09 Thread Keyur Kalaria

Hi there,

I need your help if you can help me.

I use php4 with it's session management features.
I want to count how many users are logged on my site. I use session_register
with the user ids stored in it. Now is it possible that i can get how many
people are logged in it.


Thanks in advance.

keyur




-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10241: php_flag dosn't work in httpd.conf, but it works in .htaccess files

2001-04-09 Thread vl

From: [EMAIL PROTECTED]
Operating system: linux
PHP version:  4.0.4pl1
PHP Bug Type: *Configuration Issues
Bug description:  php_flag dosn't work in httpd.conf, but it works in .htaccess files

Hi

Maybe I have missunderstud something but I thought that
directives like php_value, php_flag, php_admin_value and 
php_admin_flag may be used in httpd.conf. This doesn't 
seem to be the case with php4.0.4pl1. I have tried it both 
in global, VirtualHost and in a directory section. It 
always cause this error message:
# httpd -t
Syntax error on line 1196 of /etc/httpd/conf/httpd.conf:
Invalid command 'php_flag', perhaps mis-spelled or defined 
by a module not included in the server configuration

I have php4 installed for sure

Then I tried to put the statment in a .htaccess   
filephp_flag magic_quotes_gpc off
Then it worked

System is apache 1.3.14, php-4.0.4pl1, redhat6.2 and 
redhat7.0
./configure  --enable-ftp --with-xml --with-dom 
--enable-trans-sid --with-config-file-path=/etc/httpd 
--with-mysql --with-magic-quotes --with-apxs --with-ttf 
--with-qtdom --with-pgsql --with-gd --with-imap 
--includedir=/usr --with-openssl=/usr --enable-shmop 
--enable-sysvsem

Best regards
Vidar



-- 
Edit Bug report at: http://bugs.php.net/?id=10241edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] PHP 4.0 Bug #10212: php -l (lint option) still notworking in 4.0.6-dev

2001-04-09 Thread Michael Montero

Thank you so much for the help..this seems to have resolved the issue.
Several days ago I was able to compile the CVS version of PHP just fine.
Now, however, I get the following messages:

oracle.c: In function `php_minit_oracle':
oracle.c:294: warning: passing arg 1 of
`zend_register_list_destructors_ex' from incompatible pointer type
oracle.c:295: warning: passing arg 2 of
`zend_register_list_destructors_ex' from incompatible pointer type
oracle.c: In function `php_info_oracle':
oracle.c:1534: `PHP_ORACLE_DIR' undeclared (first use in this function)
oracle.c:1534: (Each undeclared identifier is reported only once
oracle.c:1534: for each function it appears in.)
oracle.c:1535: `PHP_ORACLE_SHARED_LIBADD' undeclared (first use in this
function)
make[3]: *** [oracle.lo] Error 1
make[3]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext/oracle'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext/oracle'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext'
make: *** [all-recursive] Error 1

My configure script looks like this:

"./configure" \
"--with-config-file-path=/mnt/raid/RAID00_5/opt/common/linux/php/config" \
"--with-mysql=/opt/db/mysql/product/3.23.29a-gamma/" \
"--with-oracle=/opt/db/oracle/product/current/" \
"--with-mcrypt=/usr/local/lib/" \
"--prefix=/web/webny/adm/php" \
"--with-oci8=/opt/db/oracle/product/current/" \
"--with-curl=/usr/local/lib/" \
"--disable-posix   " \
"$@"

Does not compile anymore.  Linting still works the way you described for 
PHP 4.0.5-RC6 however it still dumps core.  To be exact - it gives me the
proper error messages, THEN dumps core.

Thanks for the help.

-  Your Message May Appear Below This Line

On Fri, 6 Apr 2001, Shane Caraveo wrote:

 the default php.ini files turn off or on some things that linting needs,
 try:
 
 php -d display_errors=1 -d display_startup_errors=1 -d output_buffering=0 -l
 blah.html
 
 - Original Message -
 From: [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Friday, April 06, 2001 9:38 AM
 Subject: [PHP-DEV] PHP 4.0 Bug #10212: php -l (lint option) still not
 working in 4.0.6-dev
 
 
  From: [EMAIL PROTECTED]
  Operating system: RedHat Linux 6.2
  PHP version:  4.0 Latest CVS (06/04/2001)
  PHP Bug Type: Feature/Change Request
  Bug description:  php -l (lint option) still not working in 4.0.6-dev
 
  I have obtained the latest CVS version of PHP (4.0.6-dev).  I execute the
 following:
 
  php -l blah.html
 
  blah.html looks like this:
 
  ?
  echo "adfsdf"asdfds" ;
  ?
 
  This USED to cause PHP to core dump.  Now it returns but does not output
 and error message.  Actually, it does not seem to do anything.  Am wondering
 if this option (-l) is supported or in for future use or if this is being
 worked on.
 
  Thanks.
 
 
  --
  Edit Bug report at: http://bugs.php.net/?id=10212edit=1
 
 
 
  --
  PHP Development Mailing List http://www.php.net/
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  To contact the list administrators, e-mail: [EMAIL PROTECTED]
 
 
 
 



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP_AUTH_PW being passed when external auth is used (possible fix?)

2001-04-09 Thread D.M.Chapman


[[ apologies if this is not the place to raise this ]]

We have a problem with our apache/PHP4 web server in that it seems to be
making users passwords available as PHP_AUTH_PW - even though we are using
external authentication (mod_auth_samba). Hunting the php bug database
turns up two reports (ID# 7774 and ID# 8827) and (as far as I can see)
no fixes.

Having a dig around in the code we think the problem is line 397 of
mod_php4.c :


   if (authorization
/* !auth_type(r) */ -  line 397 
   !strcmp(getword(r-pool, authorization, ' '), "Basic")) {
  tmp = uudecode(r-pool, authorization);
  SG(request_info).auth_user = getword_nulls_nc(r-pool, tmp, ':');
 if (SG(request_info).auth_user) {
 SG(request_info).auth_user = estrdup(SG(request_info).auth_user);
 }
 SG(request_info).auth_password = tmp;
 if (SG(request_info).auth_password) {
SG(request_info).auth_password = estrdup(SG(request_info).auth_password);
 }
  } else {
 SG(request_info).auth_user = NULL;
 SG(request_info).auth_password = NULL;
  }


Uncommenting the line " !auth_type(r)" seems to cure the problem in my
quick test but before I roll this into service can someone who knows php
and the apache API better than me comment please!

I am a little concerned that I am missing some horrible side effect of
uncommenting this - after all, someone commented it out as looking at an
old source tree (4.0b2 I think) I can see that the check was there. It
had been commented out by version 4.0.1pl1.

Have I missed something here or is this the fix (my C is a little rusty to
say the least! :-). Why was this commented out (I suspect a test release
that "escaped")

Any clues? This is fairly urgent as I presents somewhat of a security hole
on our web server!!

Thanks,

-- 
Darren Chapman
Senior Computing Officer
University of Kent, Canterbury, England



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10218 Updated: preg_replace() with mod e, refs $10 - $19 don't work

2001-04-09 Thread andrei

ID: 10218
Updated by: andrei
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Assigned
Bug Type: *Regular Expressions
Assigned To: andrei
Comments:



Previous Comments:
---

[2001-04-06 20:39:07] [EMAIL PROTECTED]
When using preg_replace() with the modifier "e", references 
of the form \3 or $3 don't work correctly for the numbers 
10-19, while they do for 0-9  20-29. A reference to $15 is 
interpreted as a reference to $1 concatenated with the 
number 5. 

Example:

$numbers = "(one) (two) (3) (4) (5) (6) (7) (8) (9) (10) 
(11) (12) (13) (14) (15#5) (16) (17) (18) (19) (20) (21) 
(22) (23)";

$pat_without_mod = "/$numbers/";

$pat_with_e_mod = "/$numbers/e";

$text = "one two 3 4 5 6 7 8 9 10 11 12 13 14 15#5 16 17 18 
19 20 21 22 23";

echo preg_replace($pat_without_mod, "'\1 \15 \21'", 
$text);
// 'one 15#5 21'

echo preg_replace($pat_with_e_mod, "'\1 \15 \21'", 
$text);
// one one5 21

echo preg_replace($pat_without_mod, "'$1 $15 $21'", $text);
// 'one 15#5 21'

echo preg_replace($pat_with_e_mod, "'$1 $15 $21'", $text);
// one one5 21


Configure line (via phpinfo() - I'm not the admin):
'./configure' '--with-apache=../apache_1.3.17' 
'--with-mysql=/usr/local' '--with-jpeg-dir=../jpeg-6b' 
'--with-png' '--with-gd=/usr/local' '--with-ndbm' 
'--without-ttf' '--enable-safe-mode' '--enable-dbase' 
'--enable-filepro' '--enable-ftp' '--disable-debug'

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10218edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10242: constant mon doesn't exist

2001-04-09 Thread ledieudragon

From: [EMAIL PROTECTED]
Operating system: Windows ME
PHP version:  4.0.4pl1
PHP Bug Type: Date/time related
Bug description:  constant "mon" doesn't exist




-- 
Edit Bug report at: http://bugs.php.net/?id=10242edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Re: [PEAR-DEV] Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Chuck Hagenbuch

Quoting Derick Rethans [EMAIL PROTECTED]:

 I would go for optionally on, I really dont want to build both the apache
 module (p.e.) AND the CGi at the same time. For QA testing this is fine,
 but not for production servers.

But if the PEAR installer is going to depend on the cgi version of php, we're
going to need it installed on machines by default. Making people build php twice
in order to use PEAR is going to kill user acceptance.

-chuck

--
Charles Hagenbuch, [EMAIL PROTECTED]
Number of U.S. nuclear bombs lost in accidents and never recovered: 11

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Anil Madhavapeddy

Sascha Schumann wrote:

 No.  The alternative is to pass --enable-cgi on the command-line.

?

This doesn't work (nor is it listed in the --help options to configure)
I mean to compile a CGI and APXS DSO in a single compile, not two.  My
understanding is that only one SAPI module can be selected at a time
right now.  I would love to stand corrected; it's one of my prime
problems with the OpenBSD port right now.

 If the administrator installs it unknowingly, the CGI might
 get installed with inproper permissions which lead to
 potential security problems.

It's not SUID, so what's the problem?  A clear note in the NEWS file
that this behaviour has changed should be enough for administrators of
chrooted or otherwise secured systems (if they blindly update without
examining changes, then they aren't running a very tight ship anyway).

 I respect the wishes of the QA
 team, but please don't force your will upon all PHP users in
 exchange for a bit of convenience.

If PHP doesn't start installing a CGI by default, then PEAR is going to
have a few problems - its installer depends on that CGI.  And how many
end users actually run regression tests right now?  If the CGI is there
in /usr/local/bin, then a lot more users can do this, instead of just
the small QA team.  CPAN feedback from 'make test' must be quite useful
to them ...

Anil


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Warning: fopen(php://stdin,r) - Invalid argument in ...

2001-04-09 Thread Olivier Bourrassé

Hi,
I keep getting this message, I'm trying to retreive infos sent using POST.

Is that the right way to do it? The stram comes from an application so I
can't use HTTP_POST_VARS.

Is there any special configuration since I took this code from the WEB and
it's supposed to work fine.

$fp = fopen("php://stdin","r");

if ($fp){
 while (!feof($fp))

  $BUFFER = fgetc($fp);
  $INPUT .= $BUFFER;
  if ($BUFFER == "\n")
   break;
 }
}

I'm running  PHP4.04Pl1, apache 1.3.14 on NT4

Thanks
Olivier



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10181 Updated: odbc_result causes Unexpected network read error

2001-04-09 Thread kalowsky

ID: 10181
Updated by: kalowsky
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: ODBC related
Assigned To: 
Comments:

is this the latest version of OpenLink?

Previous Comments:
---

[2001-04-05 06:37:50] [EMAIL PROTECTED]
Configuration bulld with

'./configure' '--with-openlink=/opt' '--sysconfdir=/etc' 
'--with-apxs=/var/lib/apache/sbin/apxs'

Problem also occures when using --with-iodbc

The database I connect to is a Progress 7.3E15 database. Using the odbctest program 
all works fine: i.e. it does not seem to be a problem with the openlink or iodbc code.

This is the code that results in the error

HTML
HEAD
TITLEQuery ps_mstr/TITLE
/HEAD
BODY
?php
$part = '9450001';  
putenv("LD_LIBRARY_PATH=/opt/odbcsdk/lib");
putenv("ODBCINI=/etc/odbc.ini");

$dsn = "DSN=qaddb";
$sql = "select ps_comp from ps_mstr where ps_par = '$part'";

echo "PQuery is $sql/Pn";
if ($conn_id = odbc_connect("$dsn","","")) {
echo "PDatabase connection succeeded/Pn";
if ($result = odbc_do($conn_id, "$sql")) {
echo "PQuery succesfully submitted/Pn";
/*
odbc_result_all($result);
*/
while (odbc_fetch_row($result)) {
$comp = odbc_result($result, 1);
echo "P$comp/Pn";
}
odbc_free_result($result);
} else {
echo "PProblem submitting query/Pn";
}
odbc_close($conn_id);
} else {
}

?

Using lynx as a browser, I get the following errors:

Alert!: Unexpected network read error; connection aborted.


The code works fine if I give $part the value "STRATOS". It seems that the code breaks 
when the query looks for records with key values that start with a number _and_ when 
more than one row is being returned. 

odbc_result_all also gives strange. The output with odbc_result_all and $part = 
9450001 looks like:

ps_comp 
Openlink_DSN=qaddb___2 
Openlink_DSN=qaddb___2 
Openlink_DSN=qaddb___2 
Openlink_DSN=qaddb___2 
Openlink_DSN=qaddb___2 

The php.ini file is the same as php.ini-dist expect for output buffering being 
enabled.

Hope this helps

TIA

Frans Schneider
work: [EMAIL PROTECTED]
home: [EMAIL PROTECTED]

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10181edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10242 Updated: constant mon doesn't exist

2001-04-09 Thread hholzgra

ID: 10242
Updated by: hholzgra
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Bogus
Bug Type: Date/time related
Assigned To: 
Comments:

and where / why should it?
this is by far not enough information 
to do anything about it 
unless one had a working cristal ball device

please reopen or resubmit if you can provide
more information but make sure you have read
the Dos  Don'ts before submitting a bug report
as mentioned at the very top of the submission 
form

http://www.php.net/bugs-dos-and-donts.php

Previous Comments:
---

[2001-04-09 10:05:56] [EMAIL PROTECTED]


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10242edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] /ext/oci8/oci8.c win32 bugfix.

2001-04-09 Thread Paco Ortiz

Hi:

as far as I know, OCI8 works fine for me under Win32 + IIS 4 + ISAPI filter. Not that 
I tested it
heavily, but it's just my experience.

Greetings,

F.J.Ortiz


4/9/01 12:51:48 AM, "Joe Brown" [EMAIL PROTECTED] wrote:

If someone would apply this patch to ext/oci8/oci8.c I think the Oracle
using Win32 community would be greatful.

Don't know if all threaded environments have a problem with OCI8's behaviour
in threaded mode.  PHP on win32 really doesn't like it...  I haven't been
able to get it to crash with this modification.  W/out this modification I
haven't been able to keep it from crashing.

This change only affects builds on Win32, making OCI8 behave like it does on
traditional Unix.  If possible, please include in the next RC or final
release of 4.0.6

Thanks,
joebrown
podiatryfl.com

--- php4/ext/oci8/oci8.c  Fri Mar 02 04:45:08 2001
+++ php4/ext/oci8/oci8.c  Mon Apr 09 03:33:10 2001
@@ -342,7 +342,7 @@
 {
zend_class_entry oci_lob_class_entry;

-#ifdef ZTS
+#if ZTS  !WIN32
 #define PHP_OCI_INIT_MODE OCI_THREADED
 #else
 #define PHP_OCI_INIT_MODE OCI_DEFAULT



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]



___
Francisco Javier Ortiz Torre
ComuNET,S.A.
mailto:[EMAIL PROTECTED]

ComuNET, S.A
Gral. Concha 39,6
48012 Bilbao Espaa
Tel: +34 944 700 101 
Fax: +34 944 700 185 
http://www.comunet.es
___



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10243: sys/resource.h file incorrectly not included

2001-04-09 Thread jules

From: [EMAIL PROTECTED]
Operating system: linux 2.4/glibc 2.1
PHP version:  4.0.4pl1
PHP Bug Type: Compile Failure
Bug description:  sys/resource.h file incorrectly not included

Running the configure script on my system (a SuSE 6.3 system upgraded to kernel 2.4 
and glibc 2.1) causes the
classic 'microtime.c' errors as described in the FAQ,
except that the local header files are not incorrect in any fashion and edit 
main/php_config.h to define HAVE_SYS_RESOURCE_H causes the problem to go away.  

This appears therefore to be an error in the configure script - should this definition 
not be included whenever sys/resource.h exists?



-- 
Edit Bug report at: http://bugs.php.net/?id=10243edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] printf argument swapping patch

2001-04-09 Thread Morten Poulsen

Hi,

Rasmus Lerdorf [EMAIL PROTECTED] said:
 Would you mind writing a test case or two to go along with this patch?
 See the tests/README file for help on how to write these.

no, of cause. The attached patch also contains four more tests for
printf (tests/strings/002.phpt), which tests the added feature.

-- 
mortenp

Thus spake the master programmer: "Let the programmers be many and the
managers few -- then all will be productive."


diff -ur php-4.0.4pl1.orig/ext/standard/formatted_print.c 
php-4.0.4pl1/ext/standard/formatted_print.c
--- php-4.0.4pl1.orig/ext/standard/formatted_print.cFri Apr  6 16:07:49 2001
+++ php-4.0.4pl1/ext/standard/formatted_print.c Mon Apr  9 16:33:42 2001
@@ -390,8 +390,8 @@
 php_formatted_print(int ht, int *len)
 {
pval ***args;
-   int argc, size = 240, inpos = 0, outpos = 0;
-   int alignment, width, precision, currarg, adjusting;
+   int argc, size = 240, inpos = 0, outpos = 0, temppos;
+   int alignment, width, precision, currarg, adjusting, argnum;
char *format, *result, padding;
 
argc = ZEND_NUM_ARGS();
@@ -437,7 +437,23 @@
PRINTF_DEBUG(("sprintf: first looking at '%c', inpos=%d\n",
  format[inpos], inpos));
if (isascii((int)format[inpos])  
!isalpha((int)format[inpos])) {
-   /* first look for modifiers */
+   /* first look for argnum */
+   temppos = inpos;
+   while (isdigit((int)format[temppos])) temppos++;
+   if (format[temppos] == '$') {
+   argnum = php_sprintf_getnumber(format, inpos);
+   inpos++;  /* skip the '$' */
+   } else {
+   argnum = currarg++;
+   }
+   if (argnum = argc) {
+   efree(result);
+   efree(args);
+   php_error(E_WARNING, "%s(): too few 
+arguments",get_active_function_name());
+   return NULL;
+   }
+
+   /* after argnum comes modifiers */
PRINTF_DEBUG(("sprintf: looking for modifiers\n"
  "sprintf: now looking at 
'%c', inpos=%d\n",
  format[inpos], inpos));
@@ -469,7 +485,7 @@
}
PRINTF_DEBUG(("sprintf: width=%d\n", width));
 
-   /* after width comes precision */
+   /* after width and argnum comes precision */
if (format[inpos] == '.') {
inpos++;
PRINTF_DEBUG(("sprintf: getting precision\n"));
@@ -486,6 +502,7 @@
PRINTF_DEBUG(("sprintf: precision=%d\n", precision));
} else {
width = precision = 0;
+   argnum = currarg++;
}
 
if (format[inpos] == 'l') {
@@ -495,67 +512,67 @@
/* now we expect to find a type specifier */
switch (format[inpos]) {
case 's':
-   convert_to_string_ex(args[currarg]);
+   convert_to_string_ex(args[argnum]);
php_sprintf_appendstring(result, outpos, 
size,
-  
  (*args[currarg])-value.str.val,
+  
+  (*args[argnum])-value.str.val,
   
  width, precision, padding,
   
  alignment,
-  
  (*args[currarg])-value.str.len,
+  
+  (*args[argnum])-value.str.len,
   
  0, expprec);
break;
 
case 'd':
-   convert_to_long_ex(args[currarg]);
+   convert_to_long_ex(args[argnum]);

[PHP-DEV] PHP 4.0 Bug #6734 Updated: SQL Error In using ODBC connection to Oracle

2001-04-09 Thread kalowsky

ID: 6734
Updated by: kalowsky
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: ODBC related
Assigned To: 
Comments:

Is this still valid in the current PHP releases?

Second, if it is, is your Oracle setup configured to allow your Win98 machine access?

Previous Comments:
---

[2000-09-14 01:23:04] [EMAIL PROTECTED]
Installed PHP4.02 on NT 4 and 98.  NT has IIS3/PWS and 98 has PWS.  Install went fine 
on 98 after following numerous notes.  After installing on NT scripts are able to run, 
however I am unable to connect to Oracle DB.  I haven't figured out where the oracle 
module is (or how to install it for PHP) so I use ODBC connection and script.  Granted 
the code isn't pretty as I get errors with the output, but it works on the 98 machine 
fine.  

I get the following error:

Warning: SQL error: [Oracle][ODBC][Ora]Server rejected the connection., SQL state 
08004 in SQLConnect in D:Reportsbad.php on line 19
Error in odbc_connect 
Warning: Supplied argument is not a valid ODBC result resource in D:Reportsbad.php on 
line 14

Suggestions and instructions needed.

Code also follows:

?
//__
//
//  test_odbc.php3
//  A sample PHP script to test ODBC under PHP / WinNT 
//  Leo West - 08/1998
//__
 
 
function Error_Handler( $msg, $cnx )
{
echo "$msg n";
// in case of persistent connexion, it is important to close it before 
exiting.
odbc_free_result( $cnx);
exit();
}
 
// create an ODBC connection, returned in $cnx
$cnx = odbc_connect( "WebDB","SA","");
 
//  To avoid permission troubles in the test, you may want to use a superadmin 
access :
//  $cnx = odbc_connect( 'WebDB' , [sa login] , [sa password] );
 
if( ! $cnx ) {
Error_handler( "Error in odbc_connect" , $cnx );
}
 
// send a simple odbc query . returns an odbc cursor 
$cur= odbc_exec( $cnx, "select name from matters order by name" );
if( ! $cur ) {
Error_handler( "Error in odbc_exec( no cursor returned ) " , $cnx );
}
 
 
echo "table border=1trthid/ththnom/th/trn";
$nbrow=0;
 
// fetch the succesive result rows
while( odbc_fetch_row( $cur ) )
{
$nbrow++;
// get the field "id" 
$id= odbc_result( $cur, 1 );
// get the field "nom"
$nom= odbc_result( $cur, 2 );
echo "trtd$id/tdtd$nom/td/trn";
}
 
echo "trtd colspan=2$nbrow entries /td/tr/table";

// close the connection. important if persistent connection are "On"
odbc_close( $cnx);
 
?



---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=6734edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #6294 Updated: Strange behaviour when using DB2

2001-04-09 Thread kalowsky

ID: 6294
Updated by: kalowsky
Reported By: [EMAIL PROTECTED]
Status: Open
Bug Type: ODBC related
Assigned To: 
Comments:

Judging by your second comment, would you consider this bug closed?

Previous Comments:
---

[2000-08-22 11:26:07] [EMAIL PROTECTED]
I have been able to narrow the problem down to the useage of the "FOR BIT DATA" 
modifier to the CHAR type.

To use the GENERATE_UNIQUE() function in DB2, one must have a CHAR(13) FOR BIT DATA 
field. When working with a table with such a field, PHP seems to choke and do many 
strange things.. Now that I redesigned the database into just using plain CHAR(13) 
fields (planning to use uniqid()), everything seems to work a lot better.


-Eirik

---

[2000-08-22 09:34:14] [EMAIL PROTECTED]
Hi!

Having installed DB2 and compiled PHP with --with-ibm-db2 option, set the environment 
properly and started apache/php, I have the following situation:

Connecting to the database works fine.
Inserting data into tables in a database works fine, it seems. I can view the data 
using the command line interface to DB2 or any other tool.

Selecting from a table, however, is rather flakey, at best.

In my case, doing a "SELECT * FROM bar" seems to work, but when using 
odbc_result_all() to print the result set, the first field (an ID field, CHAR(13) BIT 
DATA) shows as either empty or with strange data. This strange data is, in this case, 
either "ml" (part of "html"??) or "/usr/bin:/usr/sbin:/usr/local/bin:" .. 
Seems to be a environment variable on my system.
When running it through PHP4 for OS/2 instead, these "strange data" are either "ml" 
or parts of the SQL statement.

Doing a "SELECT foo FROM bar" returns nothing at all, even though the exact same 
statement returns the data I want in any other tool I use to manage the database.


This sounds to me like a nasty bug - pointer problems or something? - in your code.. 
Either that, or it's something stupid I've done. ;)

Hope this can be resolved as soon as possible, since we're about to do a company-wide 
transition from MySQL to DB2 these days. This encounter is a serious set-back ..


Best regards,
Eirik Overby
Freepoint Networks GmbH
Haburg,
Germany

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=6294edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10204 Updated: fgets causes memory leaks

2001-04-09 Thread pallmall

ID: 10204
User Update by: [EMAIL PROTECTED]
Old-Status: Feedback
Status: Open
Bug Type: Sockets related
Description: fgets causes memory leaks

 I am in the process of working on a file abstraction for this stuff, so it will be 
rewritten. 

Hmm. I'm already using an abstraction layer; Net_Socket from PEAR. I had to modify the 
readLine method to read a byte at a time until it encounters \n to workaround the 
fgets bug.

 Maybe I haven't looked hard enough. Please let me know if $page = null works around 
the problem for now.

No it doesn't.

Previous Comments:
---

[2001-04-09 07:57:22] [EMAIL PROTECTED]
Sorry - I somehow missed the unset.

However, unset just removes the variable from the symbol table - try using $page = 
null instead.

I am in the process of working on a file abstraction for this stuff, so it will be 
rewritten.

The wierd thing is that I really can't see why fgets would behave differently from 
fread.  Maybe I haven't looked hard enough.

Please let me know if $page = null works around the problem for now.

---

[2001-04-09 07:29:57] [EMAIL PROTECTED]
 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

---

[2001-04-09 06:58:37] [EMAIL PROTECTED]
 Um, yes, the memory usage increases because you are appending an infinite number of 
copies
of the google page to your $page variable.

No, that's what the unset is for.

Anyways, here's memory statistics.

On loading script one: 3740kb RAM used after two iterations (RAM should not increase 
above this level).

After 5 minutes: 4130kb.

Cf script two: 3752kb RAM used initially, and 3752kb after 5 minutes. 

These statistics aren't especially dramatic, but in other conditions it can be 
catastrophic.

Regarding fclose, no this doesn't help.

There is a problem with fgets but not fread.

---

[2001-04-06 09:19:49] [EMAIL PROTECTED]
Um, yes, the memory usage increases because you are appending an infinite number of 
copies of the google page to your $page variable.

I can't see any leak in PHP - no leaks are reported by the memory manager.

Can you give me more information about how the memory usage increases, and what you 
would expect it to be?

Could you try explicitly fclose()ing your $fps too - you might find it useful in 
reducing memory cost.

--Wez.

---

[2001-04-06 08:54:33] [EMAIL PROTECTED]
I noticed this last night in the socket code: it uses a simple read-buffering scheme 
where the read buffer will only grow, so we are effectively storing the everything we 
have read in memory.

However, I would expect the behaviour to be the same with fread.

I take it the memory usage returns to normal once the page has completed?

--Wez.

---

The remainder of the comments for this report are too long.  To view the rest of the 
comments, please view the bug report online.

Full Bug description available at: http://bugs.php.net/?id=10204


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] CGI on by default patches..

2001-04-09 Thread Jani Taskinen


Thank you very much for breaking the compile Stig.

It still breaks after Sascha's 'fix' when using
--with-apxs. And I don't want to spend my time (again)
to find out why. I would expect you guys to know better
and TEST before committing anything that has something
to do with configure/compile. And if you don't have
all SAPIs (in this case) to test with, then ASK before
committing.

--Jani



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10245 Updated: Error when compiling with Oracle support

2001-04-09 Thread jmoore

ID: 10245
Updated by: jmoore
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Closed
Bug Type: Compile Failure
Assigned To: 
Comments:

Jani fixed this in CVS.

- James

Previous Comments:
---

[2001-04-09 11:47:25] [EMAIL PROTECTED]
When compiling the latest version with Oracle support I get the following:

oracle.c: In function `php_minit_oracle':
oracle.c:294: warning: passing arg 1 of `zend_register_list_destructors_ex' from 
incompatible pointer type
oracle.c:295: warning: passing arg 2 of `zend_register_list_destructors_ex' from 
incompatible pointer type
oracle.c: In function `php_info_oracle':
oracle.c:1534: `PHP_ORACLE_DIR' undeclared (first use in this function)
oracle.c:1534: (Each undeclared identifier is reported only once
oracle.c:1534: for each function it appears in.)
oracle.c:1535: `PHP_ORACLE_SHARED_LIBADD' undeclared (first use in this function)
make[3]: *** [oracle.lo] Error 1
make[3]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext/oracle'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext/oracle'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/INSTALLED_SOFTWARE/php4/ext'
make: *** [all-recursive] Error 1

I have configured with the following:

"./configure" 
"--with-config-file-path=/mnt/raid/RAID00_5/opt/common/linux/php/config" 
"--with-mysql=/opt/db/mysql/product/3.23.29a-gamma/" 
"--with-oracle=/opt/db/oracle/product/current/" 
"--with-mcrypt=/usr/local/lib/" 
"--prefix=/web/webny/adm/php" 
"--with-oci8=/opt/db/oracle/product/current/" 
"--with-curl=/usr/local/lib/" 
"--disable-posix   " 
"$@"

I downloaded and installed the latest CVS tree on April 6th without this warning.

Thanks.

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10245edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Would anybody find this useful besides me?

2001-04-09 Thread Chris Newbill

Just curious to see if anybody else would see the usefulness of having a
masking print function?  I dunno maybe call it mprint().

Where I could pass my mask, my value and optionally the mask char,
defaulting to something off I guess like "~".

mprint ( mask , value [, mask_char])

So I could

 $str = mprint("(XXX) XXX.", "4064498056", "X");
 print $str;

and would get

(406) 449.8056


Chris Newbill
OneWest.net Inc.,
Programmer/Analyst

406.449.8056
[EMAIL PROTECTED]

/*
Windows crashed.
I am the Blue Screen of Death.
No one hears your screams.
*/




-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10246: Lint option WORKS, but still dumps core

2001-04-09 Thread mmontero

From: [EMAIL PROTECTED]
Operating system: RedHat Linux 7.0
PHP version:  4.0 Latest CVS (09/04/2001)
PHP Bug Type: Reproduceable crash
Bug description:  Lint option WORKS, but still dumps core

Am using the latest CVS version, configured as follows:

"./configure" \
"--with-config-file-path=/mnt/raid/RAID00_5/opt/common/linux/php/config" \
"--with-mysql=/opt/db/mysql/product/3.23.29a-gamma/" \
"--with-oracle=/opt/db/oracle/product/current/" \
"--with-mcrypt=/usr/local/lib/" \
"--prefix=/web/webny/adm/php" \
"--with-oci8=/opt/db/oracle/product/current/" \
"--with-curl=/usr/local/lib/" \
"--disable-posix   " \
"$@"

I am executing the resultant executable like this:

./php -d display_errors=1 -d display_startup_errors=1 -d output_buffering=0 -q -l 
blah.html

blah.html looks like this:

?
echo "adfsdf"adfsdaf" ;
?

I get this output:

br
bParse error/b:  parse error, expecting `','' or `';'' in bblah.html/b on line 
b2/bbr
Segmentation fault (core dumped)





-- 
Edit Bug report at: http://bugs.php.net/?id=10246edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10246 Updated: Lint option WORKS, but still dumps core

2001-04-09 Thread mmontero

ID: 10246
User Update by: [EMAIL PROTECTED]
Status: Open
Bug Type: Reproduceable crash
Description: Lint option WORKS, but still dumps core

I have also run this example as follows (eliminating the complexity of any switches):

./php blah.html

I get this output:

X-Powered-By: PHP/4.0.6-dev
Content-type: text/html

br
bParse error/b:  parse error, expecting `','' or `';'' in bblah.html/b on line 
b2/bbr
Segmentation fault (core dumped)

Previous Comments:
---

[2001-04-09 12:09:21] [EMAIL PROTECTED]
Am using the latest CVS version, configured as follows:

"./configure" 
"--with-config-file-path=/mnt/raid/RAID00_5/opt/common/linux/php/config" 
"--with-mysql=/opt/db/mysql/product/3.23.29a-gamma/" 
"--with-oracle=/opt/db/oracle/product/current/" 
"--with-mcrypt=/usr/local/lib/" 
"--prefix=/web/webny/adm/php" 
"--with-oci8=/opt/db/oracle/product/current/" 
"--with-curl=/usr/local/lib/" 
"--disable-posix   " 
"$@"

I am executing the resultant executable like this:

./php -d display_errors=1 -d display_startup_errors=1 -d output_buffering=0 -q -l 
blah.html

blah.html looks like this:

?
echo "adfsdf"adfsdaf" ;
?

I get this output:

br
bParse error/b:  parse error, expecting `','' or `';'' in bblah.html/b on line 
b2/bbr
Segmentation fault (core dumped)




---


Full Bug description available at: http://bugs.php.net/?id=10246


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10247 Updated: call a VB com

2001-04-09 Thread hholzgra

ID: 10247
Updated by: hholzgra
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Bogus
Bug Type: Unknown/Other Function
Assigned To: 
Comments:

you have read the "Do's and Don'ts" document
refered to at the very top of the bug submission 
form (http://www.php.net/bugs-dos-and-donts.php)?

most likely not

anyway, this is a BUG DATABASE, not a SUPPORT FORUM,
please ask support question on the [EMAIL PROTECTED]
mailinglist, you'll find subscription info for this
list and a lot of others in the support section on
http://php.net

Previous Comments:
---

[2001-04-09 12:19:24] [EMAIL PROTECTED]
How to call VB com?
Why I can't use the variant type from VB?
How I get the columns of 2D array?

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10247edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10248: ctype_lower doesn't work.

2001-04-09 Thread tomr

From: [EMAIL PROTECTED]
Operating system: Solaris 5.7
PHP version:  4.0.4pl1
PHP Bug Type: Strings related
Bug description:  ctype_lower doesn't work.

Using ctype_lower gives an error

[09-Apr-2001 12:02:05] PHP Fatal error:  Call to undefined function:  ctype_lower() in 
/home/tom/cvs/www/production/atfi/testSymbol.php3 on line 12

this function is supposed to be defined in PHP 4.0.4 and we are 
running 4.0.4p1.



-- 
Edit Bug report at: http://bugs.php.net/?id=10248edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10241 Updated: php_flag dosn't work in httpd.conf, but it works in .htaccess files

2001-04-09 Thread ohrn

ID: 10241
Updated by: ohrn
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: *Configuration Issues
Assigned To: 
Comments:

This actually bit me yesterday.

It seems that Apache hasn't retrived the new options from dynamically loaded modules 
at the time it parses the config file.

Upgrading to Apache 1.3.19 solved it for me. Also make sure to place the php options 
after the LoadModuleAddModule directives in your config file.

Please report if this solves your problem.

Previous Comments:
---

[2001-04-09 08:45:06] [EMAIL PROTECTED]
Hi

Maybe I have missunderstud something but I thought that
directives like php_value, php_flag, php_admin_value and 
php_admin_flag may be used in httpd.conf. This doesn't 
seem to be the case with php4.0.4pl1. I have tried it both 
in global, VirtualHost and in a directory section. It 
always cause this error message:
# httpd -t
Syntax error on line 1196 of /etc/httpd/conf/httpd.conf:
Invalid command 'php_flag', perhaps mis-spelled or defined 
by a module not included in the server configuration

I have php4 installed for sure

Then I tried to put the statment in a .htaccess   
filephp_flag magic_quotes_gpc off
Then it worked

System is apache 1.3.14, php-4.0.4pl1, redhat6.2 and 
redhat7.0
./configure  --enable-ftp --with-xml --with-dom 
--enable-trans-sid --with-config-file-path=/etc/httpd 
--with-mysql --with-magic-quotes --with-apxs --with-ttf 
--with-qtdom --with-pgsql --with-gd --with-imap 
--includedir=/usr --with-openssl=/usr --enable-shmop 
--enable-sysvsem

Best regards
Vidar


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10241edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Segfault with current cvs

2001-04-09 Thread Jon Parise

Today's build is giving me this when I try to start Apache with PHP
compiled as a DSO:

Program received signal SIGSEGV, Segmentation fault.
0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
227 REMOVE_POINTER_FROM_LIST(p);

./configure \
--with-apxs=/usr/local/apache/bin/apxs \
--with-config-file-path=/usr/local/apache/conf \
--enable-ftp \
--with-gettext \
--with-imap=/usr/local \
--without-mysql \
--with-pgsql=/usr/local/pgsql \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-xml

Any thoughts?

-- 
Jon Parise ([EMAIL PROTECTED])  .  Rochester Inst. of Technology
http://www.csh.rit.edu/~jon/  :  Computer Science House Member

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] RE: PHP 4.0 Bug #6734 Updated: SQL Error In using ODBC connection to Oracle

2001-04-09 Thread Eric Ballou

Last time I checked it was still valid.  I was still unable to access on the
NT 4.0 SP6/Windows 2000 box.

Sincerely,

Eric Ballou

-Original Message-
From: Bug Database [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 09, 2001 11:08 AM
To: [EMAIL PROTECTED]
Subject: PHP 4.0 Bug #6734 Updated: SQL Error In using ODBC connection to
Oracle

ID: 6734
Updated by: kalowsky
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: ODBC related
Assigned To:
Comments:

Is this still valid in the current PHP releases?

Second, if it is, is your Oracle setup configured to allow your Win98
machine access?

Previous Comments:
---

[2000-09-14 01:23:04] [EMAIL PROTECTED]
Installed PHP4.02 on NT 4 and 98.  NT has IIS3/PWS and 98 has PWS.  Install
went fine on 98 after following numerous notes.  After installing on NT
scripts are able to run, however I am unable to connect to Oracle DB.  I
haven't figured out where the oracle module is (or how to install it for
PHP) so I use ODBC connection and script.  Granted the code isn't pretty as
I get errors with the output, but it works on the 98 machine fine.

I get the following error:

Warning: SQL error: [Oracle][ODBC][Ora]Server rejected the connection., SQL
state 08004 in SQLConnect in D:Reportsbad.php on line 19
Error in odbc_connect
Warning: Supplied argument is not a valid ODBC result resource in
D:Reportsbad.php on line 14

Suggestions and instructions needed.

Code also follows:

?
//__
//
//  test_odbc.php3
//  A sample PHP script to test ODBC under PHP / WinNT
//  Leo West - 08/1998
//__


function Error_Handler( $msg, $cnx )
{
echo "$msg n";
// in case of persistent connexion, it is important to close
it before exiting.
odbc_free_result( $cnx);
exit();
}

// create an ODBC connection, returned in $cnx
$cnx = odbc_connect( "WebDB","SA","");

//  To avoid permission troubles in the test, you may want to use a
superadmin access :
//  $cnx = odbc_connect( 'WebDB' , [sa login] , [sa password] );

if( ! $cnx ) {
Error_handler( "Error in odbc_connect" , $cnx );
}

// send a simple odbc query . returns an odbc cursor
$cur= odbc_exec( $cnx, "select name from matters order by name" );
if( ! $cur ) {
Error_handler( "Error in odbc_exec( no cursor returned ) " ,
$cnx );
}


echo "table border=1trthid/ththnom/th/trn";
$nbrow=0;

// fetch the succesive result rows
while( odbc_fetch_row( $cur ) )
{
$nbrow++;
// get the field "id"
$id= odbc_result( $cur, 1 );
// get the field "nom"
$nom= odbc_result( $cur, 2 );
echo "trtd$id/tdtd$nom/td/trn";
}

echo "trtd colspan=2$nbrow entries /td/tr/table";

// close the connection. important if persistent connection
are "On"
odbc_close( $cnx);

?



---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=6734edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10249 Updated: Duplicate name

2001-04-09 Thread mcarthy

ID: 10249
User Update by: [EMAIL PROTECTED]
Status: Open
Bug Type: Apache related
Description: Duplicate name

Added php user with UID-510

No change in errormessages - Apache still down

Previous Comments:
---

[2001-04-09 14:58:53] [EMAIL PROTECTED]
Apache v1.3 and php v3 apparently came with SuSE distribution
Apache working

I installed php-4.0.4pl1

./configure --with-apxs=/usr/sbin/apxs 
--enable-versioning 
--with-mysql=/usr/local/mysql 
--enable-track-vars

Build, make, and make install seemed to work fine. Copied php.ini-dist to /etc/httpd

Apache won't start - found these error messages in /var/log/httpd/error_log:

PHP Warning:  Function registration failed - duplicate name - define in Unknown on 
line 0
PHP Warning:  Function registration failed - duplicate name - defined in Unknown on 
line 0
PHP Warning:  Function registration failed - duplicate name - each in Unknown on line 
0
PHP Warning:  Function registration failed - duplicate name - strlen in Unknown on 
line 0
PHP Warning:  Function registration failed - duplicate name - strcmp in Unknown on 
line 0
PHP Warning:  Function registration failed - duplicate name - strcasecmp in Unknown on 
line 0
PHP Warning:  Function registration failed - duplicate name - error_reporting in 
Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - leak in Unknown on line 
0
PHP Warning:  Function registration failed - duplicate name - function_exists in 
Unknown on line 0
PHP Warning:  Basic Functions:  Unable to register functions, unable to load in 
Unknown on line 0

Added include_path = /usr/local/php-4.0.4pl1

Same errors as above

Apache still not working - can you help?

---


Full Bug description available at: http://bugs.php.net/?id=10249


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Segfault with current cvs

2001-04-09 Thread Jani Taskinen


Umm..backtrace?

--Jani


On Mon, 9 Apr 2001, Jon Parise wrote:

Today's build is giving me this when I try to start Apache with PHP
compiled as a DSO:

Program received signal SIGSEGV, Segmentation fault.
0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
227 REMOVE_POINTER_FROM_LIST(p);

./configure \
--with-apxs=/usr/local/apache/bin/apxs \
--with-config-file-path=/usr/local/apache/conf \
--enable-ftp \
--with-gettext \
--with-imap=/usr/local \
--without-mysql \
--with-pgsql=/usr/local/pgsql \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-xml

Any thoughts?




-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Segfault with current cvs

2001-04-09 Thread Jon Parise

On Mon, Apr 09, 2001 at 09:11:42PM +0200, Jani Taskinen wrote:

 Today's build is giving me this when I try to start Apache with PHP
 compiled as a DSO:
 
 Program received signal SIGSEGV, Segmentation fault.
 0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
 227 REMOVE_POINTER_FROM_LIST(p);
 
 ./configure \
 --with-apxs=/usr/local/apache/bin/apxs \
 --with-config-file-path=/usr/local/apache/conf \
 --enable-ftp \
 --with-gettext \
 --with-imap=/usr/local \
 --without-mysql \
 --with-pgsql=/usr/local/pgsql \
 --enable-sockets \
 --enable-sysvsem \
 --enable-sysvshm \
 --enable-xml
 
 Any thoughts?

 Umm..backtrace?
 
 --Jani

Woops.  Sorry about that.  I was rushing before.

Program received signal SIGSEGV, Segmentation fault.
0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
227 REMOVE_POINTER_FROM_LIST(p);
(gdb) bt
#0  0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
#1  0x281e41c5 in _zval_dtor (zvalue=0x80d9140) at zend_variables.c:62
#2  0x281d1e6e in free_zend_constant (c=0x80d9140) at zend_constants.c:31
#3  0x281e8c97 in zend_hash_destroy (ht=0x80b9380) at zend_hash.c:564
#4  0x281d221c in zend_shutdown_constants () at zend_constants.c:153
#5  0x281e4ccf in zend_shutdown () at zend.c:444
#6  0x281f63f4 in php_module_shutdown () at main.c:925
#7  0x281f63bc in php_module_shutdown_wrapper (sapi_globals=0x282ae800) at main.c:900
#8  0x281f44ec in apache_php_module_shutdown_wrapper () at mod_php4.c:694
#9  0x8050b75 in run_cleanups ()
#10 0x804f22b in ap_clear_pool ()
#11 0x805fee4 in standalone_main ()
#12 0x806083c in main ()
#13 0x804eaa1 in _start ()

-- 
Jon Parise ([EMAIL PROTECTED])  .  Rochester Inst. of Technology
http://www.csh.rit.edu/~jon/  :  Computer Science House Member

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10250: UnixODBC can make use of SQLDriverConnect functionality too

2001-04-09 Thread dzoll

From: [EMAIL PROTECTED]
Operating system: linux
PHP version:  4.0.4pl1
PHP Bug Type: ODBC related
Bug description:  UnixODBC can make use of SQLDriverConnect functionality too

In ext/odbc/php_odbc.c: odbc_sqlconnect(), only Openlink
and Empress can make use of the SQLDriverConnect function.

UnixODBC can use SQLDriverConnect as well, and in the case
of some Easysoft ODBC connections, it *must* be able to use
the SQLDriverConnect format in order to actually connect to
the database.

I have tried changing the 
  #ifdef HAVE_EMPRESS
to
  #if defined(HAVE_EMPRESS) || defined(HAVE_UNIXODBC)
and everything worked fine, giving full access to the
SQLDriverConnect method of calling odbc_connect and
odbc_pconnect.  If this could be incorporated into a later
release, it would be very useful.

(BTW, this was tested with UnixODBC 2.0.5)




-- 
Edit Bug report at: http://bugs.php.net/?id=10250edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10251: session

2001-04-09 Thread sevketg

From: [EMAIL PROTECTED]
Operating system: win32
PHP version:  4.0.3pl1
PHP Bug Type: *Session related
Bug description:  session




-- 
Edit Bug report at: http://bugs.php.net/?id=10251edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10252: strcat() used on uninitialized string

2001-04-09 Thread dzoll

From: [EMAIL PROTECTED]
Operating system: linux
PHP version:  4.0.4pl1
PHP Bug Type: ODBC related
Bug description:  strcat() used on uninitialized string

I was getting intermittent errors connecting to databases. 
Sometimes it would work fine, sometimes my connect string
would turn to gibberish and sometimes the process would
segfault.

On further examination, in
ext/odbc/php_odbc.c:odbc_sqlconnect(), within the
if(strstr(char *)db,";") block, there is a line
"strcat(ldb,db);".  At this point in the code, ldb was just
emalloced, and had uninitialized contents.  I think strcpy()
is more appopriate here, and changing the code to this seems
to have cleared up my errors.

Thank you very much.


-- 
Edit Bug report at: http://bugs.php.net/?id=10252edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Segfault with current cvs

2001-04-09 Thread Adam Dickmeiss

Hi,

this patch seems to fix this.

RCS file: /repository/php4/ext/standard/dir.c,v
retrieving revision 1.59
diff -u -r1.59 dir.c
--- dir.c   2001/04/08 21:57:13 1.59
+++ dir.c   2001/04/09 19:28:43
@@ -141,7 +141,7 @@
 #endif
 tmpstr[0] = DEFAULT_SLASH;
 tmpstr[1] = '\0';
-REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, 0);
+REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, CONST_PERSISTENT);
 
return SUCCESS;
 }

Cheers,
  Adam

On Mon, Apr 09, 2001 at 03:15:36PM -0400, Jon Parise wrote:
 On Mon, Apr 09, 2001 at 09:11:42PM +0200, Jani Taskinen wrote:
 
  Today's build is giving me this when I try to start Apache with PHP
  compiled as a DSO:
  
  Program received signal SIGSEGV, Segmentation fault.
  0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
  227 REMOVE_POINTER_FROM_LIST(p);
  
  ./configure \
  --with-apxs=/usr/local/apache/bin/apxs \
  --with-config-file-path=/usr/local/apache/conf \
  --enable-ftp \
  --with-gettext \
  --with-imap=/usr/local \
  --without-mysql \
  --with-pgsql=/usr/local/pgsql \
  --enable-sockets \
  --enable-sysvsem \
  --enable-sysvshm \
  --enable-xml
  
  Any thoughts?
 
  Umm..backtrace?
  
  --Jani
 
 Woops.  Sorry about that.  I was rushing before.
 
 Program received signal SIGSEGV, Segmentation fault.
 0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
 227 REMOVE_POINTER_FROM_LIST(p);
 (gdb) bt
 #0  0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
 #1  0x281e41c5 in _zval_dtor (zvalue=0x80d9140) at zend_variables.c:62
 #2  0x281d1e6e in free_zend_constant (c=0x80d9140) at zend_constants.c:31
 #3  0x281e8c97 in zend_hash_destroy (ht=0x80b9380) at zend_hash.c:564
 #4  0x281d221c in zend_shutdown_constants () at zend_constants.c:153
 #5  0x281e4ccf in zend_shutdown () at zend.c:444
 #6  0x281f63f4 in php_module_shutdown () at main.c:925
 #7  0x281f63bc in php_module_shutdown_wrapper (sapi_globals=0x282ae800) at main.c:900
 #8  0x281f44ec in apache_php_module_shutdown_wrapper () at mod_php4.c:694
 #9  0x8050b75 in run_cleanups ()
 #10 0x804f22b in ap_clear_pool ()
 #11 0x805fee4 in standalone_main ()
 #12 0x806083c in main ()
 #13 0x804eaa1 in _start ()
 
 -- 
 Jon Parise ([EMAIL PROTECTED])  .  Rochester Inst. of Technology
 http://www.csh.rit.edu/~jon/  :  Computer Science House Member
 
 -- 
 PHP Development Mailing List http://www.php.net/
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
Adam Dickmeiss  mailto:[EMAIL PROTECTED]  http://www.indexdata.dk
Index Data  T: +45 33410100   Mob.: 212 212 66

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] CVS Account Request

2001-04-09 Thread CVS Account Request

Full name: WENHUI ZHANG
Email: [EMAIL PROTECTED]
ID: zhangEempress
Purpose: Update and Maintain the PHP support for Empress RDBMS

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10251 Updated: session

2001-04-09 Thread hholzgra

ID: 10251
Updated by: hholzgra
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Bogus
Bug Type: *Session related
Assigned To: 
Comments:



Previous Comments:
---

[2001-04-09 15:19:48] [EMAIL PROTECTED]


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10251edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Would anybody find this useful besides me?

2001-04-09 Thread Derick Rethans

Hi Chris,

I think this would be quite usefull for PHP (and C too BTW).

Derick

On Mon, 9 Apr 2001, Chris Newbill wrote:

 Just curious to see if anybody else would see the usefulness of having a
 masking print function?  I dunno maybe call it mprint().

 Where I could pass my mask, my value and optionally the mask char,
 defaulting to something off I guess like "~".

 mprint ( mask , value [, mask_char])

 So I could

  $str = mprint("(XXX) XXX.", "4064498056", "X");
  print $str;

 and would get

 (406) 449.8056

Derick Rethans

-
PHP: Scripting the Web - www.php.net - [EMAIL PROTECTED]
 SRM: Site Resource Manager - www.vl-srm.net
-


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Would anybody find this useful besides me?

2001-04-09 Thread Joe Brown

I wrote a little function to do something similar to that.
It's a little weak but does a fairly good job formatting.  Maybe sombody
will make it better and send me the code too ;-)

// format($element, $format)
// element=input ...
// format="(999)999- x"
// 9=numeric digit
// X=converts alpha to uppercase
// x=anything goes
// anything-else=hardcoded format literals.
// above format would take 1234567890 and conver it to (123)456-7890
// amazingly format="99/99/" doesn't add 0's but does convert 01012000
to
// 01/01/2000 it also accepts 1/1/2000 and leaves it as 1/1/2000
// but "999-99-" truncates 333-2-2 to 333-2-2444
// Use:
// form
// input type=text name=f1
onchange="this.value=inputFormat(this.value,'99/99/')"
function format ($e,$f) {
  if (($e=='') || ($f=='')) return $e;
  $r="";
  $numbers='0123456789';
  $ei=0;
  $fi=0;
  while(strcmp($ev=substr($e,$ei,1),"")  strcmp($fv=substr($f,$fi,1),""))
{
switch($fv) {
case '9':
  if (strpos($numbers,$ev)!==false) {
 $r.=$ev;
 $ei++;
 $fi++;
  }
  else { // else clause causes 1/1/1999 to be accepted as such
 if (substr($f,$fi+1,1)==$ev)
   $fi++;
 else
   $ei++;
  }
  break;
case 'X':
  $r.=strtoupper($ev);
  $ei++;
  $fi++;
  break;
case 'x':
  $r.=$ev;
  $ei++;
  $fi++;
  break;
default:
  if ($ev==$fv){
 $r.=$fv;
 $ei++;
 $fi++;
  }
  else {
 $r.=$fv;
 $fi++;
 break;
  }
}
  }
  return $r;
}

""Chris Newbill"" [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Just curious to see if anybody else would see the usefulness of having a
 masking print function?  I dunno maybe call it mprint().

 Where I could pass my mask, my value and optionally the mask char,
 defaulting to something off I guess like "~".

 mprint ( mask , value [, mask_char])

 So I could

  $str = mprint("(XXX) XXX.", "4064498056", "X");
  print $str;

 and would get

 (406) 449.8056


 Chris Newbill
 OneWest.net Inc.,
 Programmer/Analyst

 406.449.8056
 [EMAIL PROTECTED]

 /*
 Windows crashed.
 I am the Blue Screen of Death.
 No one hears your screams.
 */




 --
 PHP Development Mailing List http://www.php.net/
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail: [EMAIL PROTECTED]




-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Re: PHP 4.0 Bug #6294 Updated: Strange behaviour when using DB2

2001-04-09 Thread Eirik Overby

Hi,

Judging by your second comment, would you consider this bug closed?

No, since the GENERATE_UNIQUE() function, which relies on a FOR BIT
DATA field still won't work. It seems to be the FOR BIT DATA variants
of the CHAR fields that PHP has problems with, and even though I
haven't bumped into more situations where I need this, It sure will
happen at some point - I can imagine I'll encounter the problem when we
next month start to store product pictures in the database. A such
field type would be convenient to use, as an alternative to xLOB
fields..

Best regards,
Eirik Overby

Previous Comments:
---

[2000-08-22 11:26:07] [EMAIL PROTECTED]
I have been able to narrow the problem down to the useage of the "FOR BIT DATA" 
modifier to the CHAR type.

To use the GENERATE_UNIQUE() function in DB2, one must have a CHAR(13) FOR BIT DATA 
field. When working with a table with such a field, PHP seems to choke and do many 
strange things.. Now that I redesigned the database into just using plain CHAR(13) 
fields (planning to use uniqid()), everything seems to work a lot better.


-Eirik

---

[2000-08-22 09:34:14] [EMAIL PROTECTED]
Hi!

Having installed DB2 and compiled PHP with --with-ibm-db2 option, set the environment 
properly and started apache/php, I have the following situation:

Connecting to the database works fine.
Inserting data into tables in a database works fine, it seems. I can view the data 
using the command line interface to DB2 or any other tool.

Selecting from a table, however, is rather flakey, at best.

In my case, doing a "SELECT * FROM bar" seems to work, but when using 
odbc_result_all() to print the result set, the first field (an ID field, CHAR(13) BIT 
DATA) shows as either empty or with strange data. This strange data is, in this case, 
either "ml" (part of "html"??) or "/usr/bin:/usr/sbin:/usr/local/bin:" .. 
Seems to be a environment variable on my system.
When running it through PHP4 for OS/2 instead, these "strange data" are either "ml" 
or parts of the SQL statement.

Doing a "SELECT foo FROM bar" returns nothing at all, even though the exact same 
statement returns the data I want in any other tool I use to manage the database.


This sounds to me like a nasty bug - pointer problems or something? - in your code.. 
Either that, or it's something stupid I've done. ;)

Hope this can be resolved as soon as possible, since we're about to do a company-wide 
transition from MySQL to DB2 these days. This encounter is a serious set-back ..


Best regards,
Eirik Overby
Freepoint Networks GmbH
Haburg,
Germany

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=6294edit=2





-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DEV] Segfault with current cvs

2001-04-09 Thread Sean R. Bright

Thanks.

Applied, tested and committed.

Sean

 -Original Message-
 From: Adam Dickmeiss [mailto:[EMAIL PROTECTED]]
 Sent: Monday, April 09, 2001 3:33 PM
 To: Jani Taskinen; [EMAIL PROTECTED]
 Subject: Re: [PHP-DEV] Segfault with current cvs
 
 
 Hi,
 
 this patch seems to fix this.
 
 RCS file: /repository/php4/ext/standard/dir.c,v
 retrieving revision 1.59
 diff -u -r1.59 dir.c
 --- dir.c 2001/04/08 21:57:13 1.59
 +++ dir.c 2001/04/09 19:28:43
 @@ -141,7 +141,7 @@
  #endif
  tmpstr[0] = DEFAULT_SLASH;
  tmpstr[1] = '\0';
 -REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, 0);
 +REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, 
 CONST_PERSISTENT);
  
   return SUCCESS;
  }
 
 Cheers,
   Adam
 
 On Mon, Apr 09, 2001 at 03:15:36PM -0400, Jon Parise wrote:
  On Mon, Apr 09, 2001 at 09:11:42PM +0200, Jani Taskinen wrote:
  
   Today's build is giving me this when I try to start 
 Apache with PHP
   compiled as a DSO:
   
   Program received signal SIGSEGV, Segmentation fault.
   0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
   227 REMOVE_POINTER_FROM_LIST(p);
   
   ./configure \
   --with-apxs=/usr/local/apache/bin/apxs \
   --with-config-file-path=/usr/local/apache/conf \
   --enable-ftp \
   --with-gettext \
   --with-imap=/usr/local \
   --without-mysql \
   --with-pgsql=/usr/local/pgsql \
   --enable-sockets \
   --enable-sysvsem \
   --enable-sysvshm \
   --enable-xml
   
   Any thoughts?
  
   Umm..backtrace?
   
   --Jani
  
  Woops.  Sorry about that.  I was rushing before.
  
  Program received signal SIGSEGV, Segmentation fault.
  0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
  227 REMOVE_POINTER_FROM_LIST(p);
  (gdb) bt
  #0  0x281cc7b1 in _efree (ptr=0x282c8650) at zend_alloc.c:227
  #1  0x281e41c5 in _zval_dtor (zvalue=0x80d9140) at 
 zend_variables.c:62
  #2  0x281d1e6e in free_zend_constant (c=0x80d9140) at 
 zend_constants.c:31
  #3  0x281e8c97 in zend_hash_destroy (ht=0x80b9380) at 
 zend_hash.c:564
  #4  0x281d221c in zend_shutdown_constants () at zend_constants.c:153
  #5  0x281e4ccf in zend_shutdown () at zend.c:444
  #6  0x281f63f4 in php_module_shutdown () at main.c:925
  #7  0x281f63bc in php_module_shutdown_wrapper 
 (sapi_globals=0x282ae800) at main.c:900
  #8  0x281f44ec in apache_php_module_shutdown_wrapper () at 
 mod_php4.c:694
  #9  0x8050b75 in run_cleanups ()
  #10 0x804f22b in ap_clear_pool ()
  #11 0x805fee4 in standalone_main ()
  #12 0x806083c in main ()
  #13 0x804eaa1 in _start ()
  
  -- 
  Jon Parise ([EMAIL PROTECTED])  .  Rochester Inst. of Technology
  http://www.csh.rit.edu/~jon/  :  Computer Science House Member
  
  -- 
  PHP Development Mailing List http://www.php.net/
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  To contact the list administrators, e-mail: 
 [EMAIL PROTECTED]
 
 -- 
 Adam Dickmeiss  mailto:[EMAIL PROTECTED]  http://www.indexdata.dk
 Index Data  T: +45 33410100   Mob.: 212 212 66
 
 -- 
 PHP Development Mailing List http://www.php.net/
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail: 
 [EMAIL PROTECTED]
 

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DEV] Would anybody find this useful besides me?

2001-04-09 Thread Chris Newbill

I've got a PHP coded version already, I was just looking at the interest in
having this part of the language.

My approach is more simplistic, I've never had a problem with it.

  function mprint($mask, $value, $mask_char = "X")
  {
  if (empty($value))
  return false;

  $retval = ""; // init return value
  $vp = 0; // value position

  for ($i=0; $istrlen($mask); $i++) {
  if ($mask[$i] == $mask_char) {
  // append char to retval
  $retval .= $value[$vp];
  $vp++; // increment position
  } else {
  $retval .= $mask[$i]; // don't mess with this char
  }
  }

  if ($vp != strlen($value))
  $retval .= substr($value,$vp,strlen($value)); // append left-overs

  return $retval;
  } /* end of function mprint() */

-Chris

-Original Message-
From: Joe Brown [mailto:[EMAIL PROTECTED]]
Sent: Monday, 09 April, 2001 2-44 pM
To: [EMAIL PROTECTED]
Subject: Re: [PHP-DEV] Would anybody find this useful besides me?


I wrote a little function to do something similar to that.
It's a little weak but does a fairly good job formatting.  Maybe sombody
will make it better and send me the code too ;-)

// format($element, $format)
// element=input ...
// format="(999)999- x"
// 9=numeric digit
// X=converts alpha to uppercase
// x=anything goes
// anything-else=hardcoded format literals.
// above format would take 1234567890 and conver it to (123)456-7890
// amazingly format="99/99/" doesn't add 0's but does convert 01012000
to
// 01/01/2000 it also accepts 1/1/2000 and leaves it as 1/1/2000
// but "999-99-" truncates 333-2-2 to 333-2-2444
// Use:
// form
// input type=text name=f1
onchange="this.value=inputFormat(this.value,'99/99/')"
function format ($e,$f) {
  if (($e=='') || ($f=='')) return $e;
  $r="";
  $numbers='0123456789';
  $ei=0;
  $fi=0;
  while(strcmp($ev=substr($e,$ei,1),"")  strcmp($fv=substr($f,$fi,1),""))
{
switch($fv) {
case '9':
  if (strpos($numbers,$ev)!==false) {
 $r.=$ev;
 $ei++;
 $fi++;
  }
  else { // else clause causes 1/1/1999 to be accepted as such
 if (substr($f,$fi+1,1)==$ev)
   $fi++;
 else
   $ei++;
  }
  break;
case 'X':
  $r.=strtoupper($ev);
  $ei++;
  $fi++;
  break;
case 'x':
  $r.=$ev;
  $ei++;
  $fi++;
  break;
default:
  if ($ev==$fv){
 $r.=$fv;
 $ei++;
 $fi++;
  }
  else {
 $r.=$fv;
 $fi++;
 break;
  }
}
  }
  return $r;
}

""Chris Newbill"" [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Just curious to see if anybody else would see the usefulness of having a
 masking print function?  I dunno maybe call it mprint().

 Where I could pass my mask, my value and optionally the mask char,
 defaulting to something off I guess like "~".

 mprint ( mask , value [, mask_char])

 So I could

  $str = mprint("(XXX) XXX.", "4064498056", "X");
  print $str;

 and would get

 (406) 449.8056


 Chris Newbill
 OneWest.net Inc.,
 Programmer/Analyst

 406.449.8056
 [EMAIL PROTECTED]

 /*
 Windows crashed.
 I am the Blue Screen of Death.
 No one hears your screams.
 */




 --
 PHP Development Mailing List http://www.php.net/
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail: [EMAIL PROTECTED]




--
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Segfault with current cvs

2001-04-09 Thread Jon Parise

On Mon, Apr 09, 2001 at 09:33:19PM +0200, Adam Dickmeiss wrote:

 this patch seems to fix this.
 
 RCS file: /repository/php4/ext/standard/dir.c,v
 retrieving revision 1.59
 diff -u -r1.59 dir.c
 --- dir.c 2001/04/08 21:57:13 1.59
 +++ dir.c 2001/04/09 19:28:43
 @@ -141,7 +141,7 @@
  #endif
  tmpstr[0] = DEFAULT_SLASH;
  tmpstr[1] = '\0';
 -REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, 0);
 +REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, CONST_PERSISTENT);
  
   return SUCCESS;
  }

Indeed it has.  It looks like it's already been committed, too.

Thanks!

-- 
Jon Parise ([EMAIL PROTECTED])  .  Rochester Inst. of Technology
http://www.csh.rit.edu/~jon/  :  Computer Science House Member

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10253: fopen returns pointer to empty file

2001-04-09 Thread mlane

From: [EMAIL PROTECTED]
Operating system: Slackware Current
PHP version:  4.0.3pl1
PHP Bug Type: Filesystem function related
Bug description:  fopen returns pointer to empty file

?
$fp=fopen ("/usr/local/apache/htdocs/sales.nationalonline.ca/test/test.file", "r+");
print $fp;
if (!$fp) print "error";
else $rt=filesize($fp);
print $rt;
print "blue:";
?
 Resource id #1blue:



-- 
Edit Bug report at: http://bugs.php.net/?id=10253edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Stig Sæther Bakken

[Jon Parise [EMAIL PROTECTED]]
 On Sun, Apr 08, 2001 at 06:21:50PM -0400, Stig Sther Bakken wrote:
 
  1. Using --datadir to determine where PEAR PHP files go.  With
 --datadir=/usr/share or --datadir=/usr/share/php, PHP architecture
 independent files go to /usr/share/php, and PEAR's PHP files go to
 /usr/share/php/pear.
  
 I've added your --with-pear option to override this.
  
  2. Using --libdir to determine where extensions go.  With
 --libdir=/usr/lib or --libdir=/usr/lib/php, extensions are
 installed in /usr/lib/php/APIVER.  I've also shortened the
 APIVER part so "no-debug" and "non-zts" are skipped.  The 
 alternatives are now "20001222", "20001222-zts", "20001222-debug"
 and "20001222-zts-debug".
 
 Both of these sounds good to me.
  
  3. Using --sysconfdir to determine php.ini path.  The default is now
 $prefix/etc.
 
 Would this be a replacement for --with-config-file-path?

It sets a default, and you can make do with only --sysconfdir, but
right now --with-config-file-path overrides it.

  4. The CGI version of PHP is always built and installed.
 
 I assume that would --bindir, right?

Yup.

  Let me know if you have any problems with these changes.  They should
  make it a lot easier for distributions to build PHP, because we
  conform more to de-facto build conventions (at least on Linux).  Also
  you won't have to re-run configure and make to build the CGI in order
  to run tests, the PEAR installer etc.
 
 I think you're proposed changes cover a lot more (useful) ground than
 my simple patch.  Go for it! =)

I'm going, I'm going. :-)

 - Stig

-- 
  Stig Sther Bakken [EMAIL PROTECTED]
  Fast Search  Transfer ASA, Trondheim, Norway

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] RE: [PEAR-DEV] Re: [PHP-DEV] Re: [PEAR-DEV] --with-pear[=DIR] patch

2001-04-09 Thread Stig Sæther Bakken

[Derick Rethans [EMAIL PROTECTED]]
 On Mon, 9 Apr 2001, James Moore wrote:
 
 
4. The CGI version of PHP is always built and installed.
  
   I think this should be optional.
 
  Perhaps optionally disabled.. --without-cgi?
 
 I would go for optionally on, I really dont want to build both the apache
 module (p.e.) AND the CGi at the same time. For QA testing this is fine,
 but not for production servers.

If you want to use the PEAR tools, you need the CGI version.  These
are definitely intended for production servers.

 - Stig

-- 
  Stig Sther Bakken [EMAIL PROTECTED]
  Fast Search  Transfer ASA, Trondheim, Norway

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10254: xml_set_object() and segmentation fault

2001-04-09 Thread mnino

From: [EMAIL PROTECTED]
Operating system: Redhat 6.2
PHP version:  4.0.4pl1
PHP Bug Type: XML related
Bug description:  xml_set_object() and segmentation fault

I am receiving "segmentation fault" when using xml_set_object() and setting handlers 
in the constructor. I moved them to the parse() method and the crashes stop. I found 
the resolution for a similiar issue in the feedback thread at the end of 
xml_set_object() documentation just in case you guys are already aware of this issue : 
)

Feedback Thread
===
[EMAIL PROTECTED]
06-Dec-2000 12:42 
If xml_set_object is not called in the constructor of an object, the values that the 
parser modifies will be saved. Else, the values do not seem to be saved as stated by 
"i_sofer" above. 
--- Start Example Code --- 
class foo { 
var xmlparser; 
function foo() { \\the constructor 
$this-xmlparser=xmlparser_create(); 
} 
function parse() { 
xml_set_object($this-xmlparser,$this); 
\\also include data handler 
\\and element handlers here 
} 
} 
--- End Example Code --- 


My Code
===

function parse($data) {
$this-parser = xml_parser_create();
xml_set_object($this-parser,$this);
xml_set_element_handler($this-parser,"tag_open","tag_close");
xml_set_character_data_handler($this-parser,"cdata");
xml_set_processing_instruction_handler($this-parser,"tag_pi");
xml_parse($this-parser,$data);
if (!xml_parse($this-parser, $data, 1)) {
   $error = sprintf("XML error: %s at line %d",
   xml_error_string(xml_get_error_code($this-parser)),
   xml_get_current_line_number($this-parser));
   echo $error;
} // if
xml_parser_free($this-parser);
} // fn 


-- 
Edit Bug report at: http://bugs.php.net/?id=10254edit=1



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Latest CVS crashes on Win32

2001-04-09 Thread Sebastian Bergmann

Sebastian Bergmann wrote:
   Latest CVS crashes - built as CGI - on Win32.

  Fixed now, thanks.

-- 
 sebastian bergmann[EMAIL PROTECTED]
   http://www.sebastian-bergmann.de

 bonn.phpug.de | www.php.net | www.phpOpenTracker.de | www.titanchat.de

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Re: --with-pear[=DIR] patch

2001-04-09 Thread Derick Rethans

On Mon, 9 Apr 2001, Chuck Hagenbuch wrote:

 Quoting Derick Rethans [EMAIL PROTECTED]:

  I would go for optionally on, I really dont want to build both the apache
  module (p.e.) AND the CGi at the same time. For QA testing this is fine,
  but not for production servers.

 But if the PEAR installer is going to depend on the cgi version of php, we're
 going to need it installed on machines by default. Making people build php
 twice in order to use PEAR is going to kill user acceptance.

I didn't meant it shouldn't be build both, I only would like to see if
it's optional to build the CGI too, like --with-apache --enable-cgi
This would be nice for people who don't use PEAR at all, or ISP's who dont
want PEAR modules getting installed.

regards,

Derick Rethans

-
PHP: Scripting the Web - www.php.net - [EMAIL PROTECTED]
 SRM: Site Resource Manager - www.vl-srm.net
-


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10219 Updated: the dir object created using dir() does not contain the last file in the dir

2001-04-09 Thread gopinath

ID: 10219
User Update by: [EMAIL PROTECTED]
Status: Closed
Bug Type: Directory function related
Description: the dir object created using dir() does not contain the last file in the 
dir


Here is the scenario that I have.
I have an nfs mounted a filesystem on SGI Irix machne on to
an redhat 7.1 machine. The error happens within this
file system.

I tried in different directories and got the same result 
and thought it to be a generic problem. It is not.
It works just fine on the local file systems. I have
tried on other remote mounted filesystems that are
mounted from other linux machines and see no problems
there either.
(a diff between nfs2 and nfs3 possibly?)


Previous Comments:
---

[2001-04-06 21:23:50] [EMAIL PROTECTED]
Can't reproduce with CVS version, try it first and if this still continues reopen the 
report.

http://snaps.php.net/

-Chris

---

[2001-04-06 21:11:12] [EMAIL PROTECTED]

$d = dir("/etc");
echo "Handle: ".$d-handle."brn";
echo "Path: ".$d-path."brn";
while($entry=$d-read()) {
echo $entry."brn";
}
$d-close();

It lists all but the last file in the directory.

same result when I tried with opendir() and readdir() combination.
  


---


Full Bug description available at: http://bugs.php.net/?id=10219


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10255: Exec(), System or even backtics dont work

2001-04-09 Thread emailleonid

From: [EMAIL PROTECTED]
Operating system: windows 2000 SP1
PHP version:  4.0.4pl1
PHP Bug Type: Unknown/Other Function
Bug description:  Exec(), System or even backtics dont work

Exec(), System or even backtics dont work. i've tried everything. 
?php
$test = system("dir", $return_value);
echo $test;
echo $return_value;
? 
i only get 
0
as a $return_value

here is a copy of my php.ini



[PHP]

;;;
; About this file ;
;;;
; This file controls many aspects of PHP's behavior.  In order for PHP to
; read it, it must be named 'php.ini'.  PHP looks for it in the current
; working directory, in the path designated by the environment variable
; PHPRC, and in the path that was defined in compile time (in that order).
; Under Windows, the compile-time path is the Windows directory.  The
; path in which the php.ini file is looked for can be overriden using
; the -c argument in command line mode.
;
; The syntax of the file is extremely simple.  Whitespace and Lines
; beginning with a semicolon are silently ignored (as you probably guessed).
; Section headers (e.g. [Foo]) are also silently ignored, even though
; they might mean something in the future.
;
; Directives are specified using the following syntax:
; directive = value
; Directive names are *case sensitive* - foo=bar is different from FOO=bar.
;
; The value can be a string, a number, a PHP constant (e.g. E_ALL or M_PI), one
; of the INI constants (On, Off, True, False, Yes, No and None) or an expression
; (e.g. E_ALL  ~E_NOTICE), or a quoted string ("foo").
;
; Expressions in the INI file are limited to bitwise operators and parentheses:
; | bitwise OR
;  bitwise AND
; ~ bitwise NOT
; ! boolean NOT
;
; Boolean flags can be turned on using the values 1, On, True or Yes.
; They can be turned off using the values 0, Off, False or No.
;
; An empty string can be denoted by simply not writing anything after the equal
; sign, or by using the None keyword:
;
;   foo =   ; sets foo to an empty string
;   foo = none  ; sets foo to an empty string
;   foo = "none"; sets foo to the string 'none'
;
; If you use constants in your value, and these constants belong to a dynamically
; loaded extension (either a PHP extension or a Zend extension), you may only
; use these constants *after* the line that loads the extension.
;
; All the values in the php.ini-dist file correspond to the builtin
; defaults (that is, if no php.ini is used, or if you delete these lines,
; the builtin defaults will be identical).



; Language Options ;


engine  =   On  ; Enable the PHP scripting language engine 
under Apache
short_open_tag  =   On  ; allow the ? tag.  otherwise, only ?php and 
script tags are recognized.
asp_tags=   Off ; allow ASP-style % % tags
precision   =   14  ; number of significant digits displayed in 
floating point numbers
y2k_compliance  =   Off ; whether to be year 2000 compliant (will cause 
problems with non y2k compliant browsers)
output_buffering= Off   ; Output buffering allows you to send header lines 
(including cookies)
; even after you send body 
content, in the price of slowing PHP's
; output layer a bit.
; You can enable output 
buffering by in runtime by calling the output
; buffering functions, or 
enable output buffering for all files
; by setting this directive to 
On.
output_handler  =   ; You can redirect all of the output of your 
scripts to a function,
; that can be responsible to 
process or log it.  For example,
; if you set the 
output_handler to "ob_gzhandler", than output
; will be transparently 
compressed for browsers that support gzip or
; deflate encoding.  Setting 
an output handler automatically turns on
; output buffering.
implicit_flush  = Off   ; Implicit flush tells PHP to tell the output layer to 
flush itself
; automatically after every 
output block.  This is equivalent to
; calling the PHP function 
flush() after each and every call to print()

[PHP-DEV] PHP 4.0 Bug #8412 Updated: transformations hang

2001-04-09 Thread norny

ID: 8412
User Update by: [EMAIL PROTECTED]
Old-Status: Feedback
Status: Open
Bug Type: Sablotron XSL
Description: transformations hang

I don't have that machine available anymore to help test if it works or not... at 
least not in a reasonable amount of time before 4.0.5 gets out.

Previous Comments:
---

[2001-04-05 14:29:32] [EMAIL PROTECTED]
try this with the newest sablotron and php and let me know
what happens...

---

[2000-12-25 03:56:59] [EMAIL PROTECTED]
My install hangs when hitting reload a lot and my httpd processes suck up my resources 
until the script times out. It takes between 5-15 quick reloads before it hangs. This 
seems to only happen when I grab stuff from MySQL in the same script as when I'm doing 
a transformation.

' ./configure' '--with-mysql' '--enable-track-vars' '--with-mcrypt' '--enable-ftp' 
'--enable-sockets' '--with-sablot' '--enable-sablot-errors-descriptive' 
'--with-apache=../apache_1.3.14' '--with-zlib'

I'm using Sablotron 0.44.1 and Expat 1.1.2.

A script with just MySQL works fine, and a script with just a transformation works 
fine.

I don't see anything additionally descriptive about  
--enable-sablot-errors-descriptive either

---


Full Bug description available at: http://bugs.php.net/?id=8412


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10253 Updated: fopen returns pointer to empty file

2001-04-09 Thread sniper

ID: 10253
Updated by: sniper
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Bogus
Bug Type: Filesystem function related
Assigned To: 
Comments:

1. Read the manual page for filesize() at http://www.php.net/filesize
(hint: It wants a filename as parameter)

2. If this was just buggy example script and you can 
reproduce whatever happens with latest CVS snapshot from http://snaps.php.net/ then 
reopen this bug report.

--Jani


Previous Comments:
---

[2001-04-09 17:16:29] [EMAIL PROTECTED]
?
$fp=fopen ("/usr/local/apache/htdocs/sales.nationalonline.ca/test/test.file", "r+");
print $fp;
if (!$fp) print "error";
else $rt=filesize($fp);
print $rt;
print "blue:";
?
 Resource id #1blue:


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10253edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10253 Updated: fopen returns pointer to empty file

2001-04-09 Thread sniper

ID: 10253
Updated by: sniper
Reported By: [EMAIL PROTECTED]
Old-Status: Bogus
Status: Closed
Bug Type: Filesystem function related
Assigned To: 
Comments:



Previous Comments:
---

[2001-04-09 17:16:29] [EMAIL PROTECTED]
?
$fp=fopen ("/usr/local/apache/htdocs/sales.nationalonline.ca/test/test.file", "r+");
print $fp;
if (!$fp) print "error";
else $rt=filesize($fp);
print $rt;
print "blue:";
?
 Resource id #1blue:


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10253edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #8839 Updated: Blowfish encryption not correct

2001-04-09 Thread derick

ID: 8839
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old-Status: Assigned
Status: Closed
Bug Type: mcrypt related
Assigned To: derick
Comments:

Fixed in CVS

Previous Comments:
---

[2001-01-23 12:12:14] [EMAIL PROTECTED]
Just got notice that libmcrypt 2.4.9-beta has been released, and in this version they 
have swapped the meaning of "blowfish" and "blowfish-compat" mode.

So, if you try the test scripts I posted on your own server running 2.4.9-beta, then 
change "blowfish-compat" back to "blowfish".

- Colin

---

[2001-01-22 10:11:11] [EMAIL PROTECTED]
I'll take care of it as discussed with Colin and Sascha

---

[2001-01-22 10:08:13] [EMAIL PROTECTED]
The way PHP encrypts using Blowfish doesn't seem to be compatible with the published 
"standard" test cases.

I've mentioned this to the author of libmcrypt, and he fixed part of the problem (see 
the CVS verions of libmcrypt, or whatever comes after 2.4.8).  This adds a 
"blowfish-compat" mode which solves some endianness issues.

However, PHP still isn't compatible with Perl's Crypt::Blowfish, nor (I imagine) with 
any other software that uses Blowfish encryption.  Also, the 2.2.x and 2.4.x functions 
in PHP, when passed the same parameters, don't generate the same encrypted strings.

Here are links to three files: the test vectors from 
http://www.counterpane.com/vectors.txt, test scripts using 2.2.x functions and one 
using 2.4.x functions, with and without long key handling.

http://devel.easydns.com/~cmv/

All scripts generate some different results than the test vectors.  The closest to 
getting them all right, is the 2.4.x script that emulates Perl keys.  However, it 
still gives the "wrong" answer for one test case.

- Colin


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=8839edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10219 Updated: the dir object created using dir() does not contain the last file in the dir

2001-04-09 Thread sniper

ID: 10219
Updated by: sniper
Reported By: [EMAIL PROTECTED]
Status: Closed
Bug Type: Directory function related
Assigned To: 
Comments:

With a quick search on Google I found this:

http://devrandom.net/lists/nfs/0249.html

Which seems to suggest this is a bug in glibc.

--Jani


Previous Comments:
---

[2001-04-09 19:18:53] [EMAIL PROTECTED]

Here is the scenario that I have.
I have an nfs mounted a filesystem on SGI Irix machne on to
an redhat 7.1 machine. The error happens within this
file system.

I tried in different directories and got the same result 
and thought it to be a generic problem. It is not.
It works just fine on the local file systems. I have
tried on other remote mounted filesystems that are
mounted from other linux machines and see no problems
there either.
(a diff between nfs2 and nfs3 possibly?)


---

[2001-04-06 21:23:50] [EMAIL PROTECTED]
Can't reproduce with CVS version, try it first and if this still continues reopen the 
report.

http://snaps.php.net/

-Chris

---

[2001-04-06 21:11:12] [EMAIL PROTECTED]

$d = dir("/etc");
echo "Handle: ".$d-handle."brn";
echo "Path: ".$d-path."brn";
while($entry=$d-read()) {
echo $entry."brn";
}
$d-close();

It lists all but the last file in the directory.

same result when I tried with opendir() and readdir() combination.
  


---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10219edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #9241 Updated: segfault/core dump using libmcrypt 2.4.9

2001-04-09 Thread derick

ID: 9241
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old-Status: Assigned
Status: Feedback
Bug Type: mcrypt related
Assigned To: derick
Comments:

I couldn't reproduce this with mcrypt 2.4.10 and the latest CVS, can you check this 
again?

Previous Comments:
---

[2001-02-23 12:35:21] [EMAIL PROTECTED]
The PHP script?  It's right at the top of the bug report.

---

[2001-02-21 18:12:16] [EMAIL PROTECTED]
Can you post the script too that caused this backtrace?

---

[2001-02-13 13:41:23] [EMAIL PROTECTED]
Well, it seems that I need a full day now to fix all the bugs in mcrypt :)

---

[2001-02-13 12:02:08] [EMAIL PROTECTED]
The following script cause a core dump, but only with "blowfish":

?
$td = mcrypt_module_open ("blowfish", "", "ecb", "");
mcrypt_generic_init ($td, 'secret key', "

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #9324 Updated: libmcrypt 2.4.9 causes problems

2001-04-09 Thread derick

ID: 9324
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old-Status: Assigned
Status: Feedback
Bug Type: mcrypt related
Assigned To: derick
Comments:

I could not contact your site. Can you please check it with the latest CVS and 
libmcrypt 2.4.10?

Previous Comments:
---

[2001-02-18 09:37:45] [EMAIL PROTECTED]
Another one to investigate

---

[2001-02-18 09:31:29] [EMAIL PROTECTED]
on a phpinfo i get upto the mcrypt module then i get . . .

mcrypt

Fatal error: Maximum execution time of 15 seconds exceeded in 
/home/gamr/vhosts/tnt.dynomyte.net/htdocs/index.php on line 2



it was compiled against 2.4.9 not an old version then i updated mcrypt . . .

any more details SHOULD be available at http://tnt.dynomyte.net

---



ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=9324edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] RE: PHP 4.0 Bug #10237 Updated: sybase_query returns 1 instead of link id with action queries

2001-04-09 Thread Tyson Lloyd Thwaites

I see. A little bit of confusion on my part.

From the manual:
"Returns: A positive Sybase result identifier on success, or false on error.
"

I would have thought that the affected_rows function would be called on the
*resource id returned by sybase_query, as it is with odbc_num_rows.

So I conclude that sybase_query returns a resource id with select queries,
but
true/false with action queries. This is different to odbc, hence my
confusion.

Thanks

Regards,

Tyson Lloyd Thwaites
I.Te Limited
e-Commerce Division
Adelaide

Email: [EMAIL PROTECTED]
Phone: (08) 8291 3888
Fax:   (08) 8299 9403


 -Original Message-
 From: Bug Database [mailto:[EMAIL PROTECTED]]
 Sent: Monday, April 09, 2001 6:30 PM
 To: [EMAIL PROTECTED]
 Subject: PHP 4.0 Bug #10237 Updated: sybase_query returns 1 instead of
 link id with action queries


 ID: 10237
 Updated by: joey
 Reported By: [EMAIL PROTECTED]
 Old-Status: Open
 Status: Closed
 Bug Type: Sybase-ct (ctlib) related
 Assigned To:
 Comments:

 Link ID is returned by sybase_connect, not sybase_query.
 In your example, use:
 echo sybase_affected_rows($con);

 A close examination of the PHP Manual will solve this kind
 of confusion.

 Not a bug.

 Previous Comments:
 --
 -

 [2001-04-09 02:01:54] [EMAIL PROTECTED]
 sybase_query returns 1 instead of a link id when I run an
 action query. The following code reproduces the error:

 $con = sybase_connect("SYBASE", "user", "pass");
   sybase_select_db("cope");
   $qry = sybase_query("update ...", $con);

   echo sybase_affected_rows($qry);
   sybase_close($con);

 The update query works in isql.

 Here is my configure line:
 './configure' '--with-apache=../apache_1.3.19'
 '--with-sybase-ct=/opt/sybase' '--with-curl=../curl-7.7'
 '--with-mm=../mm-1.1.3' '--enable-bcmath' '--enable-calendar'
 '--enable-ctype' '--enable-exif' '--enable-ftp'
 '--enable-gd-imgstrttf' '--with-gd' '--enable-trans-sid'
 '--enable-shmop' '--enable-sockets' '--enable-sysvsem'
 '--enable-sysvshm' '--enable-wddx'

 --
 -



 ATTENTION! Do NOT reply to this email!
 To reply, use the web interface found at
 http://bugs.php.net/?id=10237edit=2



-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10196 Updated: pspell functions no longer work

2001-04-09 Thread vlad

ID: 10196
Updated by: vlad
Reported By: [EMAIL PROTECTED]
Old-Status: Open
Status: Feedback
Bug Type: Pspell related
Assigned To: 
Comments:

Suggestions:

First, make sure you remove the old pspell and aspell installation (I see you upgraded 
it).

Install the new version, go to pspell-.12/examples, build one of their examples, e.g. 
'make example-c', and try to run it as './example-c en', and make sure you can check 
words, get suggestions, etc. If it bombs around here, it is aspell/pspell problem.

Otherwise make sure you have a new snapshot (php404pl1 is too old) and tell me what 
exactly does not work (does apache segfault, or what?)

No, it shouldn't have anything to xslt extension, at least, not that I know of any 
issues. When in doubt, recompile php with pspell support only and test.

Tell me if it worked:)

Vlad


Previous Comments:
---

[2001-04-06 22:54:21] [EMAIL PROTECTED]
I have also downloaded the latest CVS and I get the same problem.

---

[2001-04-06 22:53:43] [EMAIL PROTECTED]
It wouldn't have anything to do with the sablotron xslt extension i also have compiled 
in would it? I remember reading a post on the dev list that someone had a problem with 
pspell and sablotron and how they wouldn't both work when compiled in together.

here's my configure line if that helps:
./configure --with-apache=../apache_1.3.19 --with-mysql=/usr/local 
--with-png-dir=/usr/local --with-jpeg-dir=/usr/local --with-gd=/usr/local 
--enable-bcmath --enable-trans-sid --disable-pear --disable-posix 
--with-iconv=/usr/local --with-expat-dir=/usr/local --with-sablot=/usr/local 
--enable-inline-optimization --enable-sablot-errors-descriptive --enable-memory-limit 
--disable-short-tags --with-imap --with-zlib=/usr/local --with-pspell=/usr/local 
--with-crack=/usr/local

---

[2001-04-06 22:11:11] [EMAIL PROTECTED]
I can't reproduce this with latest CVS. Please try the snapshot and if that doesn't 
work, reopen this bug report.

--Jani


---

[2001-04-06 15:38:55] [EMAIL PROTECTED]
Here is a bit of sample code:

$pspell_config = pspell_config_create("en");
$pspell_link = pspell_new_config($pspell_config);

$pspell_link does not return any value it seems.

---

[2001-04-06 14:25:42] [EMAIL PROTECTED]
Would you mind adding some example script (short) which can
be used to reproduce this? As it works for me just fine.

(with latest CVS that is)

Try also the latest snapshot from http://snaps.php.net/

--Jani


---

The remainder of the comments for this report are too long.  To view the rest of the 
comments, please view the bug report online.


ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10196edit=2


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #10256: Documentation error

2001-04-09 Thread webkid

From: [EMAIL PROTECTED]
Operating system: CGI on Apache
PHP version:  3.0.14
PHP Bug Type: Documentation problem
Bug description:  Documentation error

The ftp_connect and other ftp commands are not supported in PHP 3.0.14, as the 
documentation states. An example:

?
$id=ftp_connect("$host");
ftp_login($id, "$user", "$pass");
printf nlist($id, "/home/$user");
printf rawlist($id, "/home/$user");
ftp_quit($id);
?

Results in:

Fatal error: Call to unsupported or undefined function ftp_connect() in odd.php3 on 
line 2

This was verison of the CGI PHP 3.0.14 was wupplied with the site, so perhaps it's an 
option that was initally edited to create the infunctionality. (What's even better is 
that my providers insist that I'm using PHP 4)

Any help would be apreciated.


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] PHP 4.0 Bug #10195 Updated: https takes forever and a day to return when php is loaded in Apache

2001-04-09 Thread Clement . Ong

ID: 10195
User Update by: [EMAIL PROTECTED]
Status: Open
Bug Type: OpenSSL related
Description: https takes forever and a day to return when php is loaded in Apache

I've downloaded the latest tar :-

  php4-200104091745

I no longer have the build error and https with PHP activated and curl option 
specified now works. No more segmentation fault in the Apache error_log file.

This is wonderful. 

When starting up Apache I have the following error is this something to worry about :-

PHP Warning:  java: Unable to initialize module
Module compiled with debug=0, thread-safety=0 module API=2809
PHP compiled with debug=0, thread-safety=0 module API=20001222
These options need to match
 in Unknown on line 0



Previous Comments:
---

[2001-04-09 04:05:15] [EMAIL PROTECTED]
I tried building with the lastest build as suggested by you and the build errored when 
it came to making sapi/cgi.

I compared the MakeFile in the sapi directory between php 4.02 and the latest and they 
are different with the lastest one making reference to CGI in several places.

Also 4.02 has a Makefile in sapi/cgi whereas the latest doesn't.

Also what version of curl are you using I'm using 7.7.1.



---

[2001-04-06 11:30:28] [EMAIL PROTECTED]
Works for me just fine with latest RC of PHP 4.0.5 and latest CVS. And I have the same 
versions of openssl and mod_ssl and I have Curl enabled.

Please try the latest snapshot: http://snaps.php.net/

--Jani



---

[2001-04-06 00:48:50] [EMAIL PROTECTED]
Latest information. If I remove with-curl out from the configuration and rebuild PHP 
the problem no longer appears.

I need the curl functionality to use https within the PHP script to another secure web 
server.



---

[2001-04-05 21:07:52] [EMAIL PROTECTED]
I am running Apache 3.1.19 with mod_ssl-2.8.2-1.3.19 and OpenSSl-0.9.6 for SSL 
functionality.

Using https from my Internet Explorer 5.0 browser causes the requested web page to be 
returned after a very long wait, .eg more than 20 minutes maybe longer. Subsequent 
retrieval takes as long too.

If I have PHP disabled by removing the LoadModule and AddModule directive https works 
immediately however when I reinstate the PHP modules I would experience the problem 
again.

Other scenario :-

  1. retrieved a https page with my browser without PHP(response received 
immediately)
  2. modify httpd.conf to enable PHP
  3. restarts Apache 
  4. starts a *NEW* browser to retrieve https(waits very long)
  5. using the same browser session in step 1 to retrieve
 again using https(response received immediately)

Also noticed in the Apache errors_log file the following error :-

[FriApr 6   11:46:302001]   [notice]child   pid 2654   
 exitsignal  Segmentationfault   (11)
[FriApr 6   11:46:362001]   [notice]child   pid 2668   
 exitsignal  Segmentationfault   (11)
[FriApr 6   11:46:362001]   [notice]child   pid 2667   
 exitsignal  Segmentationfault   (11)


This is how I configure PHP :-

./configure --with-apxs=/usr/local/apache/bin/apxs 
--with-config-file-path=/etc/php 
--with-mysql=/usr 
--with-java=/usr/java/jdk1.3 
--with-ldap 
--with-imap 
--with-curl 
--with-gd 
--enable-versioning


  



---


Full Bug description available at: http://bugs.php.net/?id=10195


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]