[PHP-DEV] Fwd: curl questionnaire!
For those of you who use the cURL extension, the underlying library is putting up a little questionaire, to help get a better idea of what the cURL user community wants, feel free to go ahead and participate, the URL (without reading the attachment :) is: http://curl.haxx.se/q/ -Sterling ---BeginMessage--- Hello fellow curl users! I'd like to ask you all who read this to skip over to the curl web site and fill in the questionnaire regarding various aspects of curl. I want to know what we all think of curl, what the general people think is important, what's bad, what's good and where to put the most focus in the immediate future development. There are ten quickly answered questions that'll only take you a few minutes to fill in. Give me your view of things on this URL: http://curl.haxx.se/q/ I appreciate if you fill in your opinion only once for each individual. -- Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/ ---End Message--- -- 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 #10530 Updated: shmop.c: shmop_open() with mode a is miscoded
ID: 10530 Updated by: yohgaki Old Summary: shmop.c: shmop_open() with mode a is miscoded Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Semaphore related Operating System: Linux 2.4.4-pre5 PHP Version: 4.0.4pl1 New Comment: Fixed in CVS. Please submit bug if you find any problem. Previous Comments: [2001-04-27 16:26:57] [EMAIL PROTECTED] file: php4/ext/shmop/shmop.c The documentation states two modes for shmop_open(). a and c. While c is usefull for creation (and access), a is programmed incorrect and misdocumented (for access and other uses). Currently a is inserting the IPC_EXCL flag for (system) shmget(). This is completly useless, as IPC_EXCL is only operative when IPC_CREAT is set (which isn't). Further a inserts SHM_RDONLY for (system) shmat(). This makes an read-only attach instead of a read-write, which does not need any flags. Proposal: To let the a do what it is intended for remove line 117 and 118 from shmop.c. Furthermore the documentation could be more precise: a does never create a shm segment, while c maybe creates one. Other usefull changes to the code in this respect would brake the interface (as it is _used_ now...). Bye, Robert Edit this bug report at http://bugs.php.net/?id=10530edit=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] Bug #10656 Updated: shmop_open permissions incorrect for writing
ID: 10656 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Semaphore related Operating System: FreeBSD 4.3 (i386) PHP Version: 4.0.5 New Comment: Supposed to be fixed in CVS. Please submit bug if you find any problem. Previous Comments: [2001-05-03 22:55:44] [EMAIL PROTECTED] Basically, the shmop_open function does not allow for writing to shared memory if pre-allocated memory is opened using the ACCESS (rather than CREATE) mode. This was found when using the shmop functions for fast interprocess communication between a number of php cgi scripts. The solution to this bug was to create another mode, WRITE (w) that uses IPC_R IPC_W shm flags. To reproduce the problem:- # ** BEFORE fix modifications are made ** # ** change to php cgi directory and run server command (C) in one telnet session then run client command (A) in another. Client cannot write! echo '? $id = shmop_open(0xff00, c, 777, 1000); print Server: Got ID\n; shmop_write($id, Hello, 0); sleep(5); $in = shmop_read($id, 0,5); print Server: Got \$in\ back from client!\n; ?' | ./php -q echo '? $id = shmop_open(0xff00, a, 0,0); print ClientA: Got ID: $id\n; $in = shmop_read($id, 0,5); print ClientA: Got \$in\ from server!\n; $bytes = shmop_write($id, $text = aMode, 0); print ClientA: Wrote $text to server! ($bytes bytes)\n; sleep(12); print \n\n; ?' | ./php -q # ** shmop_open in ACCESS mode does not allow writing to shared memory! # ** So, I created a WRITE (w) mode to allow writing and left ACCESS (a) mode as read_only. # ** AFTER fix modifications are made ** # ** change to php cgi directory and run server command (C) in one telnet session then run new client command (W) in another. Client can now write. echo '? $id = shmop_open(0xff00, c, 777, 1000); print Server: Got ID\n; shmop_write($id, Hello, 0); sleep(5); $in = shmop_read($id, 0,5); print Server: Got \$in\ back from client!\n; ?' | ./php -q echo '? $id = shmop_open(0xff00, w, 0,0); print ClientW: Got ID: $id\n; $in = shmop_read($id, 0,5); print ClientW: Got \$in\ from server!\n; $bytes = shmop_write($id, $text = wMode, 0); print ClientW: Wrote $text to server! ($bytes bytes)\n; sleep(12); print \n\n; ?' | ./php -q # ** Modifications required for bug fix, include changing ext/shmop.c Existing /ext/shmop.c [shmop_open()]: /* {{{ proto int shmop_open (int key, int flags, int mode, int size) gets and attaches a shared memory segment */ PHP_FUNCTION(shmop_open) { ... if (memchr((*flags)-value.str.val, 'a', (*flags)-value.str.len)) { shmflg = SHM_RDONLY; shmop-shmflg |= IPC_EXCL; } else if (memchr((*flags)-value.str.val, 'c', (*flags)-value.str.len)) { shmop-shmflg |= IPC_CREAT; shmop-size = (*size)-value.lval; } else { php_error(E_WARNING, shmopen: access mode invalid); efree(shmop); RETURN_FALSE; } shmop-shmid = shmget(shmop-key, shmop-size, shmop-shmflg); if (shmop-shmid == -1) { php_error(E_WARNING, shmopen: can't get the block); efree(shmop); RETURN_FALSE; } ... } /* }}} */ Corrected /ext/shmop.c [shmop_open()]: /* {{{ proto int shmop_open (int key, int flags, int mode, int size) gets and attaches a shared memory segment */ PHP_FUNCTION(shmop_open) { ... if (memchr((*flags)-value.str.val, 'a', (*flags)-value.str.len)) { shmflg = SHM_RDONLY; shmop-shmflg |= IPC_EXCL; } else if (memchr((*flags)-value.str.val, 'c', (*flags)-value.str.len)) { shmop-shmflg |= IPC_CREAT; shmop-size = (*size)-value.lval; } else if (memchr((*flags)-value.str.val, 'w', (*flags)-value.str.len)) { shmop-shmflg |= IPC_R; shmop-shmflg |= IPC_EXCL; shmop-shmflg |= IPC_W; } else { php_error(E_WARNING, shmopen: access mode invalid); efree(shmop); RETURN_FALSE; } ... } /* }}} */ # * Configuration lines for php_4.0.5.tar.gz compiling ./configure --enable-memory-limit=yes --enable-sockets --with-openssl --enable-shmop --enable-debug=no --enable-xml --enable-ftp --with-config-file-path=/etc --with-mysql=/usr/local/ --with-sybase=/usr/local/freetds/
[PHP-DEV] Bug #14784 Updated: shmop_write causes segfault
ID: 14784 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Reproducible crash Operating System: Linux (RH 6.2 / 2.4.3) PHP Version: 4.1.1 New Comment: Supposed to be fixed in CVS. Please reopen bug if there is problem still. Previous Comments: [2002-01-01 23:53:08] [EMAIL PROTECTED] Backtrace with --with-debug: == Program received signal SIGSEGV, Segmentation fault. 0x40103487 in memcpy (dstpp=0x4040a000, srcpp=0x81f990c, len=96) at ../sysdeps/generic/memcpy.c:55 55 ../sysdeps/generic/memcpy.c: No such file or directory. (gdb) bt #0 0x40103487 in memcpy (dstpp=0x4040a000, srcpp= 0x81f990c, len=96) at ../sysdeps/generic/memcpy.c:55 #1 0x40285c37 in zif_arsort (ht=3, return_value=0x81f96bc, this_ptr=0x0, return_value_used=1) at array.c:444 #2 0x4022df34 in execute (op_array=0x81eeb74) at ./ zend_execute.c:1799 #3 0x4024051b in zend_parse_arg_impl (arg=0x8, va=0x0, spec=0x3) at zend_API.c:387 #4 0x40252582 in php_fopen_primary_script (file_handle= 0xb704) at fopen_wrappers.c:305 #5 0x4024d50e in should_overwrite_per_dir_entry (orig_per_dir_entry=0x8122fec, new_per_dir_entry=0x0) at mod_php4.c:646 #6 0x4024e350 in zm_info_apache (zend_module=0x8122fec) at php_apache.c:289 #7 0x4024e3cc in zif_virtual (ht=135409644, return_value= 0x805d55c, this_ptr=0x1f4, return_value_used=23) at php_apache.c:315 #8 0x80550f3 in ap_invoke_handler () #9 0x8069529 in process_request_internal () #10 0x806958c in ap_process_request () #11 0x8060a6e in child_main () #12 0x8060c20 in make_child () #13 0x8060d79 in startup_children () #14 0x80613d6 in standalone_main () #15 0x8061ba3 in main () #16 0x400bb9cb in __libc_start_main (main=0x806184c main, argc=2, argv=0xba1c, init=0x804f47c _init, fini=0x809858c _fini, rtld_fini=0x4000aea0 _dl_fini , stack_end=0xba14) at ../sysdeps/generic/libc- start.c:92 === And it's not me who's wrapping the text... [2002-01-01 15:19:08] [EMAIL PROTECTED] A backtrace without --enable-debug is pretty useless. Can you recompile and paste the backtrace again? Also, please don't wrap the lines. [2002-01-01 15:17:07] [EMAIL PROTECTED] Sorry. I forgot to include the backtrace: start Program received signal SIGSEGV, Segmentation fault. 0x40103493 in memcpy (dstpp=0x40319000, srcpp=0x81ea42c, len=1) at ../sysdeps/generic/memcpy.c:61 61 ../sysdeps/generic/memcpy.c: No such file or directory. (gdb) bt #0 0x40103493 in memcpy (dstpp=0x40319000, srcpp= 0x81ea42c, len=1) at ../sysdeps/generic/memcpy.c:61 #1 0x40583745 in ?? () from /usr/local/apache/libexec/ libphp4.so #2 0x4053f235 in ?? () from /usr/local/apache/libexec/ libphp4.so #3 0x4054e22b in ?? () from /usr/local/apache/libexec/ libphp4.so #4 0x4055f861 in ?? () from /usr/local/apache/libexec/ libphp4.so #5 0x4055c1f2 in ?? () from /usr/local/apache/libexec/ libphp4.so #6 0x4055cb56 in ?? () from /usr/local/apache/libexec/ libphp4.so #7 0x4055cb88 in ?? () from /usr/local/apache/libexec/ libphp4.so #8 0x80550f3 in ap_invoke_handler () #9 0x8069529 in process_request_internal () #10 0x806958c in ap_process_request () #11 0x8060a6e in child_main () #12 0x8060c20 in make_child () #13 0x8060d79 in startup_children () #14 0x80613d6 in standalone_main () #15 0x8061ba3 in main () #16 0x400bb9cb in __libc_start_main (main=0x806184c main, argc=2, argv=0xba2c, init=0x804f47c _init, fini=0x809858c _fini, rtld_fini=0x4000aea0 _dl_fini , stack_end=0xba24) at ../sysdeps/generic/libc- start.c:92 end mjh [2001-12-31 21:20:53] [EMAIL PROTECTED] I have been experimenting with semaphores/shmop to provide query caching for an application I am working on. The purpose, of course, bears no bearing on the issue I am reporting however as I am just doing testing of the two extensions at this point. I used this article as the starting point for my testing - http://zez.org/article/articleprint/46/. So I put together this script: -- function mtime() { return array_sum( explode( , microtime() ) ); } function supecho( $text ) { echo Pb$text/b/p\r\n; flush(); } function subecho( $text ) { echo Pb -- $text/b/p\r\n; flush(); } supecho( Starting semaphore testing... ); // Start semaphore handling $semaphoreID= sem_get( 0xee3 , 1 , 0666 ); // Get a semaphore named 0xee3 supecho(
[PHP-DEV] Bug #14898 Updated: $HTTP_POST_FILES['uploadedfile']['name'] error
ID: 14898 Comment by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: HTTP related Operating System: linux slackware8 PHP Version: 4.1.1 New Comment: ---code modified-- //s = strrchr(filenamebuf, '\\'); char *tmps; s=filenamebuf; // set initial value for (tmps=filenamebuf;*tmps;tmps++) { if (*tmps0){// *tmps127, looks like 2 bytes of chinese code if (!*(tmps+1)) tmps++; continue; } if (*tmps=='\\') s=tmps; } --code modified end --- Previous Comments: [2002-01-08 09:37:12] [EMAIL PROTECTED] the following code works well for chinese double-byte checking. ---code modified-- //s = strrchr(filenamebuf, '\\'); char *tmps; for (tmps=filenamebuf;*tmps;tmps++) { if (*tmps0){// *tmps127, looks like 2 bytes of chinese code if (!*(tmps+1)) tmps++; contonue; } if (*tmps=='\\') s=tmps; } --code modified end --- [2002-01-07 22:48:48] [EMAIL PROTECTED] the fix is too rough and can't handle all chinese words, it need more efforts to check. i will do it in a few days. [2002-01-07 01:56:48] [EMAIL PROTECTED] /* This is a bug fix for rfc1867.c try to upload file from win2k with name C:\DISK0\»\³\.txt the original code get name as '.ext' which should be '»\³\.txt'. the following modify is necessary to for client using charset=BIG5. thanks PHP. lai [EMAIL PROTECTED] */ ---code modified-- //s = strrchr(filenamebuf, '\\'); for (s=filenamebuf+strlen(filenamebuf)-1;sfilenamebuf;s--) { if (*s=='\\' *(s-1)0) break; } --code modified end --- Edit this bug report at http://bugs.php.net/?id=14898edit=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] Bug #14944: Access Violation with Cc header
From: [EMAIL PROTECTED] Operating system: Windows 2000 Professional PHP version: 4.1.0 PHP Bug Type: Mail related Bug description: Access Violation with Cc header While parsing the script displayed below, this error appears: 'PHP has encountered an Access Violation at 01130A6E'. This only happens when using the Cc header, in this script. The IIS server it is running on will not respond after the PHP error. Rebooting is the only way to restart the service. PHP script causing error: ? /* mail([EMAIL PROTECTED], My Subject, Line 1\nLine 2\nLine 3, From: webmaster@$SERVER_NAME\r\n .Reply-To: webmaster@$SERVER_NAME\r\n .X-Mailer: PHP/ . phpversion()); */ /* recipients */ $to = Mary [EMAIL PROTECTED] . , ; //note the comma $to .= Kelly [EMAIL PROTECTED]; /* subject */ $subject = Birthday Reminders for August; /* message */ $message = ' html head titleBirthday Reminders for August/title /head body pHere are the birthdays upcoming in August!/p table tr thPerson/ththDay/ththMonth/ththYear/th /tr tr tdJoe/tdtd3rd/tdtdAugust/tdtd1970/td /tr tr tdSally/tdtd17th/tdtdAugust/tdtd1973/td /tr /table /body /html '; /* To send HTML mail, you can set the Content-type header. */ $headers = MIME-Version: 1.0\n; $headers .= Content-type: text/html; charset=iso-8859-1\n; /* additional headers */ $headers .= From: Intranet webmaster@$SERVER_NAME\n; $headers .= Reply-To: Bart [EMAIL PROTECTED]\n; $headers .= Cc: [EMAIL PROTECTED]\n; /* and now mail it */ mail([EMAIL PROTECTED], $subject, $message, $headers); ? -- Edit bug report at: http://bugs.php.net/?id=14944edit=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] Bug #14944 Updated: Access Violation with Cc header
ID: 14944 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Mail related Operating System: Windows 2000 Professional PHP Version: 4.1.0 Edit this bug report at http://bugs.php.net/?id=14944edit=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] internal class..
I'm browsing through the source to the domxml extension, to check how to define and use php class as there seem to be no documentation.. my question I guess is if there is any documentation at all how to use this, or should I check the source for help? best regards Robin -- 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] internal class..
Hello, On 9 Jan 2002, Robin Ericsson wrote: I'm browsing through the source to the domxml extension, to check how to define and use php class as there seem to be no documentation.. my question I guess is if there is any documentation at all how to use this, or should I check the source for help? I've some notes on it (not really docs, I'll add it later to the ZendAPI docs), but there is an example overloaded class in basic_functions.c. That's the best way to start. Derick -- 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] internal class..
On Wed, Jan 09, 2002 at 10:49:50AM +0100, Robin Ericsson wrote : I'm browsing through the source to the domxml extension, to check how to define and use php class as there seem to be no documentation.. my question I guess is if there is any documentation at all how to use this, or should I check the source for help? Use ths source luke, it's really not that hard. Also, PHP-GTK does quite a lot OO/classes stuff so you might take a look at it. Also, it's not wrong to ask specific question on the list, I'm sure people will answer it. -- Please always Cc to me when replying to me on the lists. -- 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 #14826 Updated: 4.1.0 on powerpc doesn't save session variables
ID: 14826 User updated by: [EMAIL PROTECTED] Old Summary: 4.1.0 on powerpc doesn't save session variables Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: Session related Operating System: Debian Linux 2.2.19 ppc PHP Version: 4.1.0 New Comment: yep session related paths and setups are the same on both installs but just ppc doesnt' works with session vars Previous Comments: [2002-01-04 12:30:57] [EMAIL PROTECTED] Are you sure the session-related paths in your php.ini are correct? [2002-01-03 10:12:03] [EMAIL PROTECTED] 4.1.0 on powerpc doesn't save session variables apache 1.3.22 scripts like this sample doesn't save session varibles, but when run on intel platform with same php.ini, same php and apache versions, it works saving session variables. - ?php session_start(); // session variable to store the counter. session_register('counter'); // session variable to store the value when the page was last loaded; // this value is maintained so that difference can be calculated. session_register('timeAtLastLoad'); // current time $timeNow = time(); // increment counter $counter++; // calculate the time lapsed from last visit. $timeLapsed = $timeNow - $timeAtLastLoad; // display appropriate message if($counter 1) { echo bIt's been $timeLapsed seconds since you last viewed this page./b; } else { echo bFirst time here? Reload this page to see how the session works!/b; } $timeAtLastLoad = $timeNow; ? --- Edit this bug report at http://bugs.php.net/?id=14826edit=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] Bug #14945: session_set_save_handler causes crashes
From: [EMAIL PROTECTED] Operating system: Windows 2000 PHP version: 4.1.1 PHP Bug Type: Session related Bug description: session_set_save_handler causes crashes When PHP is loaded as an Apache module on Windows it causes some strange crashes. Works fine with IIS and cgi setups. If there is not existing active session Apache will crash once session_start() is called with the error: The instruction at 0x0058463 referenced memory at 0x04da8610. The memory could not be read. Using the PHP default file based sessions work fine, but only if session.save_handler is set to files. Using session_start() without a session_set_save_handler() will crash php if session.save_handler is set to user. Would be better if it reported an error message. If there is an existing valid session PHP works fine and there are no problems. -- Edit bug report at: http://bugs.php.net/?id=14945edit=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] Bug #14933 Updated: regular expression problem
ID: 14933 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Bogus Bug Type: Documentation problem Operating System: Win ME PHP Version: 4.1.1 Previous Comments: [2002-01-08 15:13:08] [EMAIL PROTECTED] Documentation quote: The character types \d, \D, \s, \S, \w, and \W may also appear in a character class, and add the characters that they match to the class. So, I tried to match Ttry8 with T([\da-z]{1,}) and it won't work. vs T([\da-z8]{1,}) work. !! Edit this bug report at http://bugs.php.net/?id=14933edit=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] Bug #14594 Updated: Failed to compile/run when using Apache 2.x, unresolved symbols
ID: 14594 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Apache2 related Operating System: FreeBSD 4.4-STABLE PHP Version: 4.1.0 New Comment: Exactly the same dump with 4.1.1 with apache 2.0.28 on exactly the same os. Previous Comments: [2001-12-18 18:40:35] [EMAIL PROTECTED] I compiled standard Apache-2.0.28beta, then downloaded php-4.1.0, compiled it just with --with-mysql and --with-apxs2=/usr/local/apache2/bin/apxs After sucessful make install, I tried to run /usr/local/apache2/bin/httpd, which resulted in this error: Syntax error on line 3 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apache2/modules/libphp4.so into server: /usr/local/apache2/modules/libphp4.so: Undefined symbol pthread_getspecific Edit this bug report at http://bugs.php.net/?id=14594edit=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] Bug #14515 Updated: child pid XXX exit signal Segmentation fault (11)
ID: 14515 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Critical Bug Type: Apache related Operating System: linux 2.4.16 PHP Version: 4.1.0 New Comment: I have the same problem, but in a bit different condition. php compile options: (php 4.1.1 with apache 1.3.22) ./configure --prefix=/usr/local/plesk/apache\ --with-system-regex\ --with-apache=/home/admin/apache/apache_1.3.22\ --with-config-file-path=/usr/local/plesk/apache/etc\ --with-db3=/usr/local/BerkeleyDB.3.2\ --enable-calendar\ --disable-debug\ --disable-pear\ --enable-track-vars\ --with-swf=/usr/local\ --with-mysql=/usr/local/plesk/mysql\ --with-imap\ --without-imap-ssl\ --with-mcrypt=/usr/local\ --with-dom=/usr/local\ --with-pcre\ --with-zlib-dir=/usr/local/include\ --with-mod_charset\ --enable-ftp\ --with-curl=/usr/local/include/curl\ --with-openssl=/usr/local/ssl\ --with-java=/usr/java/jdk1.3.1_01\ --with-zip=/usr/local\ --with-gd=/home/admin/apache/gd-1.8.4\ --with-jpeg-dir=/home/admin/apache/jpeg-6b\ --with-freetype-dir=/home/admin/apache/freetype-2.0.5\ --with-png-dir=/home/admin/apache/libpng-1.2.1\ the problem exactly occurs when I change the URL from http:// to https:// or vice versa. (They have the same base directory). Which I have open first on a new browser, it works, other not. PHP code is similar. Something may be related with the headers sent to browser. (sorry for broken english) Previous Comments: [2001-12-15 08:27:52] [EMAIL PROTECTED] sorry, forgot the stacktrace: (gdb) bt #0 0x40a0e333 in php_pcre_replace (regex=0x40ab8b11 /realm=\(.*?)\/i, regex_len=16, subject=0x8184455 Basic realm=\DB-RW-Access\, subject_len=27, replace_val=0x81844a4, is_callable_replace=0, result_len=0xbfffc19c, limit=-1) at php_pcre.c:768 #1 0x409bf494 in sapi_add_header_ex (header_line=0x818 WWW-Authenticate, header_line_len=44, duplicate=1 '\001', replace=1 '\001') at SAPI.c:467 #2 0x40a4b7af in zif_header (ht=1, return_value=0x8184404, this_ptr=0x0, return_value_used=0) at head.c:56 #3 0x40996697 in execute (op_array=0x81840e4) at ./zend_execute.c:1590 #4 0x409a8364 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at zend.c:814 #5 0x409bb8e1 in php_execute_script (primary_file=0xb268) at main.c:1309 #6 0x409b6220 in apache_php_module_main (r=0x816a250, display_source_mode=0) at sapi_apache.c:90 #7 0x409b71a0 in send_php (r=0x816a250, display_source_mode=0, filename=0x816bdc8 /usr/local/WWW/marticole/htdocs/PRIVATE/Hausverwaltung/resthof.php) at mod_php4.c:575 #8 0x409b7223 in send_parsed_php (r=0x816a250) at mod_php4.c:590 #9 0x806e019 in ap_invoke_handler () #10 0x8083aef in process_request_internal () #11 0x8083b62 in ap_process_request () #12 0x807a696 in child_main () #13 0x807a875 in make_child () #14 0x807a9f6 in startup_children () #15 0x807b07c in standalone_main () #16 0x807b8cc in main () #17 0x40620c6f in __libc_start_main () from /lib/libc.so.6 (gdb) [2001-12-15 08:23:37] [EMAIL PROTECTED] The only way to get some output was starting the apache inside gdb. I got the following: (gdb) run -X -f /usr/local/apache/conf/httpd.conf Starting program: /usr/local/apache/bin/httpd -X -f /usr/local/apache/conf/httpd.conf [New Thread 1024 (LWP 7109)] Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1024 (LWP 7109)] 0x40a0e333 in php_pcre_replace (regex=0x40ab8b11 /realm=\(.*?)\/i, regex_len=16, subject=0x8184455 Basic realm=\DB-RW-Access\, subject_len=27, replace_val=0x81844a4, is_callable_replace=0, result_len=0xbfffc19c, limit=-1) at php_pcre.c:768 768 if ('\\' == *walk || '$' == *walk) { (gdb) [2001-12-14 18:41:15] [EMAIL PROTECTED] Could you provide backtrace? http://bugs.php.net/bugs-generating-backtrace.php Please read how to report bug link also. [2001-12-14 09:23:20] [EMAIL PROTECTED] Hi, when i try to run the following code, my apache goes banana (child pid XXX exit signal Segmentation fault (11) in the error_log) ?php if(!isset($PHP_AUTH_USER)) { Header(WWW-Authenticate: Basic realm=\DB-RW-Access\); Header(HTTP/1.0 401 Unauthorized); echo Get lost\n; exit; } else { $dbid = $PHP_AUTH_USER; $dbpw = $PHP_AUTH_PW; } phpinfo(); exit; php-compile-time-options: './configure' '--prefix=/usr/local/php-4.1.0' '--with-apxs=/usr/local/apache/bin/apxs' '--enable-force-cgi-redirect' '--with-config-file-path=/usr/local/apache/conf' '--with-openssl' '--with-bz2' '--with-imap' '--with-gdbm' '--enable-ftp'
[PHP-DEV] Bug #14946: Undefined function ImageCreate() since I use PHP4
From: [EMAIL PROTECTED] Operating system: win NT PHP version: 4.1.0 PHP Bug Type: *Graphics related Bug description: Undefined function ImageCreate() since I use PHP4 The function ImageCreate() worked when I was on PHP3, but since monday (I upgraded on PHP4) it hasn't worked... Error Msg : Fatal Error: Call undefined function imagecreate() Thanx for your help -- Edit bug report at: http://bugs.php.net/?id=14946edit=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] Bug #14946 Updated: Undefined function ImageCreate() since I use PHP4
ID: 14946 Updated by: mfischer Reported By: [EMAIL PROTECTED] Old Status: Open Status: Bogus Bug Type: *Graphics related Operating System: win NT PHP Version: 4.1.0 New Comment: Please ask support questions at [EMAIL PROTECTED] Hint: make sure you've adjusted your php.ini properly Previous Comments: [2002-01-09 06:26:09] [EMAIL PROTECTED] The function ImageCreate() worked when I was on PHP3, but since monday (I upgraded on PHP4) it hasn't worked... Error Msg : Fatal Error: Call undefined function imagecreate() Thanx for your help Edit this bug report at http://bugs.php.net/?id=14946edit=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] Bug #14945 Updated: session_set_save_handler causes crashes
ID: 14945 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Old Status: Open Status: Duplicate Bug Type: Session related Operating System: Windows 2000 PHP Version: 4.1.1 New Comment: Dup of #14497 Previous Comments: [2002-01-09 05:30:40] [EMAIL PROTECTED] When PHP is loaded as an Apache module on Windows it causes some strange crashes. Works fine with IIS and cgi setups. If there is not existing active session Apache will crash once session_start() is called with the error: The instruction at 0x0058463 referenced memory at 0x04da8610. The memory could not be read. Using the PHP default file based sessions work fine, but only if session.save_handler is set to files. Using session_start() without a session_set_save_handler() will crash php if session.save_handler is set to user. Would be better if it reported an error message. If there is an existing valid session PHP works fine and there are no problems. Edit this bug report at http://bugs.php.net/?id=14945edit=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] Bug #14278 Updated: Analyzed: Probably OCI related? string-int type casting problem for sure!
ID: 14278 User updated by: [EMAIL PROTECTED] Old Summary: % and / bug with INTEGERs! Reported By: [EMAIL PROTECTED] Old Status: Closed Status: Open Bug Type: Math related Operating System: Linux 2.2.19 PHP Version: 4.0.6 New Comment: After some more investigation on this bug I noticed following: I have an OCI insert statement executed with a 'RETURNING INTO' clause. The value which is returned is a oracle DB entry of type NUMBER. I expected to have the returned value in PHP to be a number as well. BUT it is a string! Some more output I produced in my script is: ? echo($num (type: .gettype($num).[.strlen($num).] - .($num*1).)); ? The result (when the error occures): 106851 (type: string[6] - 1068514) As you can see the value of the $num variable changes while automatic type casting from string to int is executed. The reason for the NEW (bigger) value is possibly a not null terminated string value returned by the OCI interface. My suggestion: While typecasting from string to int an extra check should be done (e.g. detect if there is a null terminated string and if not: terminate it). Thanks for your patch! Previous Comments: [2001-12-20 12:48:09] [EMAIL PROTECTED] No feedback. Closing. [2001-11-29 15:42:41] [EMAIL PROTECTED] E:\phpphp -v 4.0.6 E:\phpphp -q test.php 101110 22 3888 14 149 19 5 5 0 0 0 0 AAFTOW No matter how many times I run this script I always get this. Also tested it on Linux (2.4), with PHP 4.2.0-dev and it works. Please try a newer version and see if that fixes the problem you're having. http://www.php.net/~zeev/php-4.1.0RC3.tar.gz or http://snaps.php.net/php4-latest.tar.gz -Chris [2001-11-29 05:27:51] [EMAIL PROTECTED] Sometimes (1 - 10 times a day) I get a strange error on one of my production servers. See this function: function MakeHash($num) { $ret = ; $ca = array(); for ($i = 0; $i 6; $i++) { $c = $num % 26; $ca[] = $num $c; $ret = sprintf(%c, 65+$c).$ret; $num = ($num-$c)/ 26; } // Send $ca array via email to me (removed) return $ret; } Sometimes calling this function with an INT it calculates wired results... If that happens I mail the $ca array to myself and see what it does: 101110 19 (MEANS: 101110 % 26 is 19!? That's wrong, it is 22) 3588 24 (MEANS 101110 / 26 is 3588, but it is 3888) 1495714 12... 57527 15 2212 2 85 7 What goes wrong? In the beginning the % result is wrong, and then the division result is wrong too... any suggestions!? /mike Edit this bug report at http://bugs.php.net/?id=14278edit=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] Compilation Bug
Hello, I'm writing to try to bring attention to a certain bug I've been having. Several people have emailed me asking if I've found a solution to compiling PHP 4.1.1 on Red Hat 7.1 with SNMP support. I have not. The bug is documented here: http://bugs.php.net/bug.php?id=14910 Any help solving this would be greatly appreciated by several people. Thanks. -- Jason Signalness, Systems Administrator Basin Telecommunications, Inc. [EMAIL PROTECTED](701)355-5727 -- -- 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 #14947: not null terminated RETURNING INTO values?
From: [EMAIL PROTECTED] Operating system: Linux PHP version: 4.0.6 PHP Bug Type: OCI8 related Bug description: not null terminated RETURNING INTO values? Please see bug report 14278 for details! ( http://bugs.php.net/bug.php?id=14278 ) Thanks, Mike -- Edit bug report at: http://bugs.php.net/?id=14947edit=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] Compilation Bug
On Wed, Jan 09, 2002 at 08:17:08AM -0600, Jason Signalness wrote : I'm writing to try to bring attention to a certain bug I've been having. Several people have emailed me asking if I've found a solution to compiling PHP 4.1.1 on Red Hat 7.1 with SNMP support. I have not. The bug is documented here: http://bugs.php.net/bug.php?id=14910 I saw similar bugs in the past, all caused by broken installations or stale header files lying around. Trying cleaning up your system and try again. I've no problems compiling 4.1.1 with ucd-snmp 4.2.3 on debian system. -- Please always Cc to me when replying to me on the lists. -- 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 #14947 Updated: not null terminated RETURNING INTO values?
ID: 14947 Updated by: mfischer Reported By: [EMAIL PROTECTED] Old Status: Open Status: Bogus Bug Type: OCI8 related Operating System: Linux PHP Version: 4.0.6 New Comment: no need for second report (the old one is still open and valid) Previous Comments: [2002-01-09 09:26:22] [EMAIL PROTECTED] Please see bug report 14278 for details! ( http://bugs.php.net/bug.php?id=14278 ) Thanks, Mike Edit this bug report at http://bugs.php.net/?id=14947edit=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] Bug #14948: mssql_pconnect opens connection everytime is called
From: [EMAIL PROTECTED] Operating system: NT 4.0 SP5 PHP version: 4.1.1 PHP Bug Type: MSSQL related Bug description: mssql_pconnect opens connection everytime is called Apache 1.3.22 Win NT SP5 PHP 4.1.1, run as DLL Apache module MSDE SQL server mod_mssql module loaded Problem: When opening connection to MSSQL database with mssql_pconnect, the connections are not persistently used. Instead, new connection is opened everytime. See MSSQL sp_who2 results: SPID Status DBName Command CPUTime DiskIO LastBatch ProgramNameSPID - -- -- --- -- -- -- - 1 sleepingmaster SIGNAL HANDLER 0 0 01/09 15:07:02 1 2 BACKGROUND UKOLY LOCK MONITOR 0 0 01/09 15:07:02 2 3 BACKGROUND UKOLY LAZY WRITER 0 0 01/09 15:07:02 3 4 sleepingUKOLY LOG WRITER 0 0 01/09 15:07:02 4 5 sleepingUKOLY CHECKPOINT SLEEP 0 0 01/09 15:07:02 5 6 BACKGROUND UKOLY AWAITING COMMAND 0 5 01/09 15:07:02 6 7 RUNNABLEUKOLY SELECT INTO 0 16901/09 15:41:39 MS SQL Query 7 8 sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:34 PHP 4.08 9 sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:31 PHP 4.09 10sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:37 PHP 4.010 11sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:39 PHP 4.011 12sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:40 PHP 4.012 13sleepingUKOLY AWAITING COMMAND 0 0 01/09 15:41:41 PHP 4.013 -- Edit bug report at: http://bugs.php.net/?id=14948edit=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] Bug #14947 Updated: not null terminated RETURNING INTO values?
ID: 14947 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Bogus Bug Type: OCI8 related Operating System: Linux PHP Version: 4.0.6 New Comment: The original bug # is OPEN but related to another topic... my intention was to have informed to oci8 interface developers as well. /mike Previous Comments: [2002-01-09 09:44:04] [EMAIL PROTECTED] no need for second report (the old one is still open and valid) [2002-01-09 09:26:22] [EMAIL PROTECTED] Please see bug report 14278 for details! ( http://bugs.php.net/bug.php?id=14278 ) Thanks, Mike Edit this bug report at http://bugs.php.net/?id=14947edit=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] Bug #14909 Updated: Allows access to ANY file
ID: 14909 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Critical Bug Type: Apache related Operating System: Windows PHP Version: 4.1.1 Assigned To: imajes New Comment: I have windows xp + apache + php 4.1 installed and the /php/ alias is also definied in my httpd.conf and therefor I am also affected by this exploit. but how can I use php WITHOUT this alias in apache conf? I tried several things but it doesn't work. chris, 15 =) Previous Comments: [2002-01-09 02:17:17] [EMAIL PROTECTED] so do we have to read the documentation again on how to install PHP?? have u added a fix? [2002-01-08 08:03:10] [EMAIL PROTECTED] the documentation is fixed, i committed this morning/last night. there is however a bug in the way apache handles the binary -- or the way php acts when called as a binary (you can get premature end of script headers). What i would like to do is leave this open, and noticeable for some of the apache guys to take a look at and comment on it. The docs are fixed we just need to wait to see if this is a thing to hand off to apache. [2002-01-08 07:16:40] [EMAIL PROTECTED] As said by others, this is NOT a bug, but a documentation problem. (btw: assigned to only needs your username) [2002-01-08 03:28:11] [EMAIL PROTECTED] Ok, I have checked in a newer, cleaner version of the relevant documentation. As far as the guidelines go, configuring php and apache like that is a massive security risk, (since we've been recommending all production level sites to create a script alias for /php/ and mapping that to their php directory), so I appeal to the apache people (Jimw, etc) to look into ways of fixing it so you don't have to use a scriptalias and action. (or use action with an absolute path). This is a pretty urgent problem, so i'm going to mark this bug as critical and move it to Apache Related. [2002-01-07 12:02:52] [EMAIL PROTECTED] Georg, our security section has a link to that CERT advisory for quite a long time now. I have added a warning and a link to the particular security page to that setup instruction page for Apache windows. Please give better instructions for CGI setups under windows if you can. A setup, where PHP sritps are portable, so no #!c:\php\php.exe type of method is doable... Maybe James can find another way. The Apache doc only documents the methods we have in the install and security chapters... --- Goba The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/?id=14909 Edit this bug report at http://bugs.php.net/?id=14909edit=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] Bug #14949: fprintf function
From: [EMAIL PROTECTED] Operating system: All PHP version: 4.1.1 PHP Bug Type: Feature/Change Request Bug description: fprintf function This issue has stumped me since I first started working with PHP (Around version 3.0.14 I believe). And I'm fairly sure I'm not the only one wondering about this. How come there is no fprintf function? I looked at the FAQ on the website (even tried submitting a comment on it). I've read a few books on PHP, and they all say there is no fprintf function. I've done numerous web searches on this question, and although I have found workarounds for the lack of this function, I never found the reason why it was excluded. I know you are all busy with other, more pressing concerns regarding PHP and its upkeep, but whatever the answer is, could you please put it in the FAQ for all to see? Thanks for your time! -- Edit bug report at: http://bugs.php.net/?id=14949edit=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] Bug #14355 Updated: ldap_connect works intermittantly
ID: 14355 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: LDAP related Operating System: Solaris 2.6 (SPARC) PHP Version: 4.0.6 New Comment: It looks like ORACLE_HOME needs to be set in order for the Oracle LDAP client to work, which is odd because I rarely need to set it to get the database client working. From what I've seen, LDAP works consistantly if I set ORACLE_HOME in the webserver's startup scripts. I don't know why the openldap stuff wasn't working. I guess the point is moot until I *have* to use openldap (which probably won't happen unless the PHP LDAP code learns how to bind w/ kerberos). Previous Comments: [2001-12-23 11:41:28] [EMAIL PROTECTED] I'm sorry, I don't have any solutions for you. I guess no one else does either. First of all, have you tried to supply an IP address, so that we can be sure it's not DNS related? Did you try to build with the Oracle 8i LDAP? You can do that with something like --with-ldap=/usr/local/oracle/product/8.1.6 It would be interesting to know whether the problem was still there. If you use OpenLDAP 2.x and very latest PHP snapshot, you can get debugging output by doing ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7); at the beginning of your script. Last parameter is a bit mask. If you don't want to use latest PHP, the easiest is to add something like int debug = 7; ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, debug); inside PHP's ldap_connect(). You could also try to add some debugging code in the OpenLDAP library (or use gdb or something). I would then try to add a printf() to the beginning of ldap_init() in libldap/open.c [2001-12-10 01:17:38] [EMAIL PROTECTED] tried it with php built into apache statically. same problem.. [2001-12-06 01:19:33] [EMAIL PROTECTED] I just watched the wire w/ tcpdump - there's no communication between the webserver and the LDAP server. [2001-12-05 18:58:28] [EMAIL PROTECTED] server config - Sun Ultra 2 (dual 300mhz IIs), 768MB RAM, Solaris 2.6 (SPARC), Apache 1.3.20, PHP 4.0.6 (and 4.0CVS- 12-0-4) configured as DSOs. I'm trying to build PHP as an apache module w/ support for LDAP (for use w/ HORDE). PHP builds fine, and apxs is able to make the .so file, but I regularly get Unable to connect to LDAP server. Apache doesn't segfault, and phpinfo() shows that LDAP support has been built in. There is no mention of it in my php error log, nor my apache error log. My build was fairly complex (including support Oracie 8i, which I disabled when I found the OpenLDAP / OCI8 / Solaris threads in the bugs database). I've tried building against OpenLDAP 1.2.12, 1.2.13, 2.0.18 and the Oracle LDAP library that ships w/ 8.1.17 (when I added --with-oci8). The most basic configuration line looks like: env CC=gcc \ CFLAGS=-I/usr/local/openldap/include \ CPPFLAGS=-I/usr/local/openldap/include \ CXXFLAGS=-I/usr/local/openldap/include \ ./configure --with-apxs=/usr/local/apache/bin/apxs \ --with-ldap=/usr/local/openldap I make distclean between re-configure and re-builds. I've tried gcc 2.95.2, 2.95.3, and the Sun Workshop (4.2) version cc. I've had no problem with PHP+LDAP when built as the CGI. The DSO has been very flakey. I've not tried building PHP directly into Apache. If the DSO works, it works until the apache is restarted. I've not kept track, but I'd say at least 75% of the time after apache is restarted (or stopped and started), LDAP doesn't work - and this behavior is consistant with the various LDAP libraries I've tried. I wish I could provide more information - is there additional debugging I can turn on, or maybe add to the C code? thanks much Edit this bug report at http://bugs.php.net/?id=14355edit=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] Bug #1027 Updated: fprintf() please
ID: 1027 Updated by: jan Reported By: [EMAIL PROTECTED] Old Status: Open Status: Duplicate Bug Type: Feature/Change Request PHP Version: 4.0 New Comment: was duped by 14949 which is more descriptive ;) Previous Comments: [2001-07-22 12:27:39] [EMAIL PROTECTED] Is fprintf going to be added or should this request be closed? [2001-02-10 12:55:39] [EMAIL PROTECTED] really moved to 4.0 this time. [2001-02-10 12:40:17] [EMAIL PROTECTED] still no fprintf. refiled against 4.0. [1999-01-05 04:09:14] [EMAIL PROTECTED] Quite often my PHP3-scripts take input from the user, and writes it into a file. I can do fputs($fp,sprintf(%2d\n,$variable)); but it really looks ghastly. Fprintf would be nice to have. I would also suggest that you take all the stdio-derived functions which is dispersed throughout the manual (in Filesystem and Strings) and collect them in a new section called File I/O or equivalent. Edit this bug report at http://bugs.php.net/?id=1027edit=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] Bug #14949: fprintf function
The answer will be : Because it can be emulated in the userspace. ?php $fp=fopen('some.txt','w+'); $some=10; fwrite($fp, sprintf(some decimal %d,$some)); fclose($fp); ? Regards, Andrey Hristov - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, January 09, 2002 4:57 PM Subject: [PHP-DEV] Bug #14949: fprintf function From: [EMAIL PROTECTED] Operating system: All PHP version: 4.1.1 PHP Bug Type: Feature/Change Request Bug description: fprintf function This issue has stumped me since I first started working with PHP (Around version 3.0.14 I believe). And I'm fairly sure I'm not the only one wondering about this. How come there is no fprintf function? I looked at the FAQ on the website (even tried submitting a comment on it). I've read a few books on PHP, and they all say there is no fprintf function. I've done numerous web searches on this question, and although I have found workarounds for the lack of this function, I never found the reason why it was excluded. I know you are all busy with other, more pressing concerns regarding PHP and its upkeep, but whatever the answer is, could you please put it in the FAQ for all to see? Thanks for your time! -- Edit bug report at: http://bugs.php.net/?id=14949edit=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]
Re: [PHP-DEV] Bug #14949: fprintf function
On Wed, Jan 09, 2002 at 05:06:19PM +0200, Andrey Hristov wrote : The answer will be : Because it can be emulated in the userspace. ?php $fp=fopen('some.txt','w+'); $some=10; fwrite($fp, sprintf(some decimal %d,$some)); fclose($fp); ? so you volunteer for a FAQ entry? :-) -- 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] Bug #14949: fprintf function
:) - Original Message - From: Markus Fischer [EMAIL PROTECTED] To: Andrey Hristov [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, January 09, 2002 5:14 PM Subject: Re: [PHP-DEV] Bug #14949: fprintf function On Wed, Jan 09, 2002 at 05:06:19PM +0200, Andrey Hristov wrote : The answer will be : Because it can be emulated in the userspace. ?php $fp=fopen('some.txt','w+'); $some=10; fwrite($fp, sprintf(some decimal %d,$some)); fclose($fp); ? so you volunteer for a FAQ entry? :-) -- 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 #12691 Updated: Apache 2: Server variables don't get set
ID: 12691 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Apache2 related Operating System: SuSE7.1 PHP Version: 4.0CVS-2001-08-10 New Comment: I am seeing the same problem with Apache 2.0.28, php 4.1.1 under RedHat Linux When I run phpinfo() all the environmental variables are missing compared to running phpinfo() with Apache 1.3.22 and php 4.1.1 Previous Comments: [2001-11-19 12:37:39] [EMAIL PROTECTED] ok, here's what I tried: o PHP4.0.2-dev (php4-2009 from snaps) o config line is: './configure' '--with-apxs2=/usr/local/apache2/bin/apxs' '--with-mysql' '--with-dom' '--disable-posix' '--disable-pic' '--with-zlib' '--enable-wddx' o Apache2.0.28-beta o config line is: CFLAGS=-g; export CFLAGS ./configure \ --enable-layout=Apache \ --enable-auth-digest \ --enable-ext-filter \ --disable-include \ --enable-headers \ --enable-so \ --enable-ssl=shared \ --with-mpm=threaded \ --enable-http \ --enable-dav=shared \ --disable-asis \ --enable-info=shared \ --enable-suexec \ --enable-cgi=shared \ --enable-cgid=shared \ --enable-dav-fs=shared \ --enable-vhost-alias=shared \ --disable-imap \ --enable-rewrite=shared \ --with-suexec-uidmin=30 \ --with-suexec-gidmin=65534 Now env vars are set ok (either with or without seting I/O filters, just with an AddType), *BUT* :) I still found that one very important one is missing, namely PATH_INFO. If I say http://teo.gecadsoftware.com/i.php/x it gives a file not found error (where i.php exists and contains a phpinfo() call). I tried to catch that with FilesMatch, but couldn't figure (I think the test for $DOCUMENT_ROOT/i.php/x to exist is done before applying matches, which makes sense). I am having a look into it but my experience with Apache2 is less that epsilon :) so maybe somebody can have a look too? [2001-11-17 12:10:10] [EMAIL PROTECTED] There has been a patch regarding this three days ago. Please try the latest snapshot from http://snaps.php.net/ and report, if the problem still comes up. [2001-11-03 21:53:17] [EMAIL PROTECTED] updated short desc. [2001-08-10 11:08:15] [EMAIL PROTECTED] hi alindeman, erm, you missed the essential 2 :) it's with Apache2 (apxs2) Additional note: printenv from /cgi-bin shows them just right. [2001-08-10 10:49:39] [EMAIL PROTECTED] works fine for me (Apache 1.3.20 + PHP Latest CVS). Try running ?phpinfo()? and see what variables are defined.. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/?id=12691 Edit this bug report at http://bugs.php.net/?id=12691edit=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] Bug #14950: __sleep() and __wakeup() fail
From: [EMAIL PROTECTED] Operating system: Debian SID PHP version: 4.0CVS-2002-01-09 PHP Bug Type: Session related Bug description: __sleep() and __wakeup() fail Passing objects using the magic __sleep() and __wakeup() methods through sessions fail. In the best case the script fails without error. In the worst, an integer in session turns into the value of the PHP session ID and the object is not registered. Yasuo Ohgaki guesses it's a serialize/unserialize problem. Make log : /usr/src/web/php/php4/ext/standard/var_unserializer.re: In function `php_var_unserialize': /usr/src/web/php/php4/ext/standard/var_unserializer.re:304: warning: comparison is always false due to limited range of data type Tests : http://php.hellekin.com/test/session/ PHPInfo() : http://php.hellekin.com/info.php -- Edit bug report at: http://bugs.php.net/?id=14950edit=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] Bug #14950 Updated: __sleep() and __wakeup() fail
ID: 14950 Comment by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Session related Operating System: Debian SID PHP Version: 4.0CVS-2002-01-09 New Comment: Forgot to tell : asking for .phps will show you the source in the /test/session/ directory. Previous Comments: [2002-01-09 10:36:08] [EMAIL PROTECTED] Passing objects using the magic __sleep() and __wakeup() methods through sessions fail. In the best case the script fails without error. In the worst, an integer in session turns into the value of the PHP session ID and the object is not registered. Yasuo Ohgaki guesses it's a serialize/unserialize problem. Make log : /usr/src/web/php/php4/ext/standard/var_unserializer.re: In function `php_var_unserialize': /usr/src/web/php/php4/ext/standard/var_unserializer.re:304: warning: comparison is always false due to limited range of data type Tests : http://php.hellekin.com/test/session/ PHPInfo() : http://php.hellekin.com/info.php Edit this bug report at http://bugs.php.net/?id=14950edit=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] Bug #14550 Updated: Basic Authentication fails
ID: 14550 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Closed Bug Type: Apache related Operating System: Debian Linux 2.4.12 PHP Version: 4.1.0 New Comment: The problem is not solved in 4.1.1, if the debian package 4.1.1-1 contains the recent bug fixes. If this is the same effect, the error shows up only if safe_mode is On. environment: debian woody on Linux finnegan 2.4.17 #11 SMP Fri Dec 28 14:41:15 CET 2001 i686 unknown packages: apache 1.3.22-5, php4 4.1.1-1 test browsers: netscape navigator 4.77, opera 6.0 TP2 Tested with the following script: ?PHP if ( !isset($PHP_AUTH_USER) || $PHP_AUTH_USER == ) { $aLog = fopen( /tmp/test.log, a ); fputs( $aLog, noauth\n ); fclose( $aLog ); Header( WWW-Authenticate: Basic realm=\test\ ); Header( HTTP/1.0 401 Unauthorized ); echo Zugriff nicht gestattet.; exit; } else { $aLog = fopen( /tmp/test.log, a ); fputs( $aLog, login: $PHP_AUTH_USER:$PHP_AUTH_PW = $bAuth\n ); fclose( $aLog ); echo Autorisation: $PHP_AUTH_USER:$PHP_AUTH_PW; } ? html headtitletest/title/head bodyh1test/h1/body /html BTW: the bugs.php.net page seems to suffer from a similar problem. opera seemed to get into a loop for a considerable amount of tries until this page did show up. or am i already seeing ghosts now? ;-) Previous Comments: [2001-12-16 16:19:42] [EMAIL PROTECTED] This should be fix in CVS now. Can you try the latest snapshot from snaps.php.net? Derick [2001-12-16 15:36:21] [EMAIL PROTECTED] fixing type. (website problem is for problems with php.net websites.) [2001-12-16 15:25:20] [EMAIL PROTECTED] HTTP: Basic Authentication fails PHP: 4.1.0 Server API: Apache (1.3.22) OS: Linux 2.4.12 (Debian) The following PHP script should trigger a basic authentication dialog in the client browser (see http://www.zend.com/manual/features.http-auth.php): ?php if(!isset($PHP_AUTH_USER)) { header(WWW-Authenticate: Basic realm=\MyRealm\); header(HTTP/1.0 401 Unauthorized); echo Text to send if user hits Cancel button\n; exit; } else { echo pHello $PHP_AUTH_USER./p; echo pYou entered $PHP_AUTH_PW as your password./p; } ? Under PHP 4.0.6. the script worked fine and the user was prompted for username and password. After the upgrade to PHP 4.1.0. the script does not produce the expected results, but leads to browser errors on the client side in most cases. In rare cases the authentication dialog appears and the script works as expected. Most of the times the browser reports an error message or shows an empty document: Netscape 4.77/Linux: the document contained no data Lynx/Linux: Unexpected network read error; connection aborted. Netscape 4.7/Win2k: the document contained no data Netscape 3.0/Win2k: the document contained no data IE 6.0/Win2k: server or dns not found Opera 5.01/Win2k: The server requested a login authentication method that is not supported Opera 6.0 (Beta TP1) / Linux: shows an empty document If examined via telnet, the server closes the connection after the URL with the above script has been requested, e.g. telnet (domain name) 80 GET /auth.php HTTP/1.1 Host: (domain name) - connection closed by server 16.12.2001 Edit this bug report at http://bugs.php.net/?id=14550edit=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] Bug #14949: fprintf function
True, but you can do the same thing in C as well, but fprintf was also implemented there :) The odd thing is, if none of the other f functions, e.g. printf, sprintf, etc. were implemented, I would understand why fprintf would also be excluded. However, PHP does an excellent job of implementing equivalent C functions, which is the reason I initially chose it as a development tool. Its almost as if fprintf was particularly single out for some reason... oh well, conspiracy theories abound! On Wed, 9 Jan 2002 17:06:19 +0200, Andrey Hristov wrote: The answer will be : Because it can be emulated in the userspace. ?php $fp=fopen('some.txt','w+'); $some=10; fwrite($fp, sprintf(some decimal %d,$some)); fclose($fp); ? Regards, Andrey Hristov Philippe Hajjar -- 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 #14052 Updated: ftp_rawlist: Hangs up
ID: 14052 Comment by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Feedback Bug Type: FTP related Operating System: Win2K PHP Version: 4.0.6 New Comment: Yes I've tested it with 4.1.1 and the problem ist still present. 90 Seconds is absolutly true! In this time he hangs in the ftp_rawlist function... and then he will continue, but often doesn't work the next call to ftp_rawlist too. And sorry, it isn't a problem of the user, but when executing per CLI, the script run more reliable than executed by apache. When I start the script directly it run sometimes until end (Not often). I tested it on 2 machines (W2K-Notebook and W2K-PC). I'm very intrested in this function, because i'm working on a little web-filesharing-tool, which should index content of ftps. Thanks for your feedback! Previous Comments: [2002-01-02 09:46:20] [EMAIL PROTECTED] Is this bug still present to you, also with 4.1.0? If so, can you verify that the 'hang' time is about 90 seconds (its a fixed coded timeout value in ext/ftp)? [2001-11-14 09:48:04] [EMAIL PROTECTED] I think there is really a problem with repeated ftp_rawlist (Reported in #7897). I write a script which make several ftp_rawlists to indexing all the content. In most case, the task hangs up for 1 or 2 minutes. Then the program will continue, but it can be that it hangs up again. When I start the script directly (cmd-line), it will run well. But when I start it trough the task scheduler or the web server, it hangs up always. I can't explain the problem more, because this is all - Repeated ftp_rawlist, script is running under user system. Edit this bug report at http://bugs.php.net/?id=14052edit=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] Bug #14052 Updated: ftp_rawlist: Hangs up
ID: 14052 Updated by: mfischer Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: FTP related Operating System: Win2K Old PHP Version: 4.0.6 PHP Version: 4.1.1 New Comment: I'm setting this to open, version to 4.1.1. Although in CVS there exists now a way to adjust the timeout (ftp_set_option(FTP_TIMEOUT_SEC, 10); for example) it's not a solution and there are still some flaws in the implementation IMO. Previous Comments: [2002-01-09 11:06:06] [EMAIL PROTECTED] Yes I've tested it with 4.1.1 and the problem ist still present. 90 Seconds is absolutly true! In this time he hangs in the ftp_rawlist function... and then he will continue, but often doesn't work the next call to ftp_rawlist too. And sorry, it isn't a problem of the user, but when executing per CLI, the script run more reliable than executed by apache. When I start the script directly it run sometimes until end (Not often). I tested it on 2 machines (W2K-Notebook and W2K-PC). I'm very intrested in this function, because i'm working on a little web-filesharing-tool, which should index content of ftps. Thanks for your feedback! [2002-01-02 09:46:20] [EMAIL PROTECTED] Is this bug still present to you, also with 4.1.0? If so, can you verify that the 'hang' time is about 90 seconds (its a fixed coded timeout value in ext/ftp)? [2001-11-14 09:48:04] [EMAIL PROTECTED] I think there is really a problem with repeated ftp_rawlist (Reported in #7897). I write a script which make several ftp_rawlists to indexing all the content. In most case, the task hangs up for 1 or 2 minutes. Then the program will continue, but it can be that it hangs up again. When I start the script directly (cmd-line), it will run well. But when I start it trough the task scheduler or the web server, it hangs up always. I can't explain the problem more, because this is all - Repeated ftp_rawlist, script is running under user system. Edit this bug report at http://bugs.php.net/?id=14052edit=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] Bug #14052 Updated: ftp_rawlist: Hangs up
ID: 14052 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Status: Open Bug Type: FTP related Operating System: Win2K PHP Version: 4.1.1 New Comment: Please update version :) Previous Comments: [2002-01-09 11:31:38] [EMAIL PROTECTED] I'm setting this to open, version to 4.1.1. Although in CVS there exists now a way to adjust the timeout (ftp_set_option(FTP_TIMEOUT_SEC, 10); for example) it's not a solution and there are still some flaws in the implementation IMO. [2002-01-09 11:06:06] [EMAIL PROTECTED] Yes I've tested it with 4.1.1 and the problem ist still present. 90 Seconds is absolutly true! In this time he hangs in the ftp_rawlist function... and then he will continue, but often doesn't work the next call to ftp_rawlist too. And sorry, it isn't a problem of the user, but when executing per CLI, the script run more reliable than executed by apache. When I start the script directly it run sometimes until end (Not often). I tested it on 2 machines (W2K-Notebook and W2K-PC). I'm very intrested in this function, because i'm working on a little web-filesharing-tool, which should index content of ftps. Thanks for your feedback! [2002-01-02 09:46:20] [EMAIL PROTECTED] Is this bug still present to you, also with 4.1.0? If so, can you verify that the 'hang' time is about 90 seconds (its a fixed coded timeout value in ext/ftp)? [2001-11-14 09:48:04] [EMAIL PROTECTED] I think there is really a problem with repeated ftp_rawlist (Reported in #7897). I write a script which make several ftp_rawlists to indexing all the content. In most case, the task hangs up for 1 or 2 minutes. Then the program will continue, but it can be that it hangs up again. When I start the script directly (cmd-line), it will run well. But when I start it trough the task scheduler or the web server, it hangs up always. I can't explain the problem more, because this is all - Repeated ftp_rawlist, script is running under user system. Edit this bug report at http://bugs.php.net/?id=14052edit=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] Bug #14951: Apache does not start after PHP compile
From: [EMAIL PROTECTED] Operating system: Solaris 2.8 PHP version: 4.1.1 PHP Bug Type: Apache related Bug description: Apache does not start after PHP compile After succesfull compilation of PHP 4.1.1, Apache failed to start with the following warning: Syntax error on line 222 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: /usr/local/apache/bin/httpd: fatal: relocation error: file /usr/local/apache/libexec/libphp4.so: symbol uncompress: referenced symbol not found My configure line was: ./configure --enable-trans-sid --with-ldap=/usr/local --with-openssl --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql I removed --with-mysql and after recompiling Apache worked fine. The MySQL that I use is 3.23.47. Thanks, Christian. -- Edit bug report at: http://bugs.php.net/?id=14951edit=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] Bug #14910 Updated: --with-snmp compile failure
ID: 14910 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Compile Failure Operating System: Red Hat Linux 7.1 PHP Version: 4.1.1 New Comment: The same error occurs when using UCD-SNMP 4.2.3. Wiping out any snmp library and header files on the system and rebuilding snmp had no effect. Previous Comments: [2002-01-07 09:35:20] [EMAIL PROTECTED] I am running UCD-SNMP 4.2.2. UCD-SNMP libraries are installed in the default locations (/usr/local/...). The snmp daemon, etc, appear to work perfectly. Configure of php suceeds. I think compilation suceeds as well. Linking appears to fail after compilation. Nobody was able to help me on the mailing lists. I have also seen several other people posting this same error to the lists. They have also received no useful answers. The configure options I used: ./configure \ --with-apxs=/opt/apache/bin/apxs \ --with-oci8 \ --with-ldap \ --with-gd=/usr \ --with-jpeg-dir=/usr \ --with-png-dir=/usr \ --with-freetype-dir=/usr \ --with-zlib-dir=/usr \ --with-xpm-dir=/usr/X11R6 \ --enable-sigchild \ --with-imap \ --enable-xslt \ --with-xslt-sablot \ --enable-wddx \ --with-snmp \ --enable-ucd-snmp-hack \ --with-openssl A snippet of the error it produced upon make: Making all in . make[1]: Entering directory `/opt/tmp/php-4.1.1' /bin/sh /opt/tmp/php-4.1.1/libtool --silent --mode=link gcc -I. -I/opt/tmp/php-4.1.1/ -I/opt/tmp/php-4.1.1/main -I/opt/ tmp/php-4.1.1 -I/opt/apache/include -I/opt/tmp/php-4.1.1/Zend -I/usr/include/freetype2/freetype -I/usr/local/include -I/ opt/tmp/php-4.1.1/ext/mysql/libmysql -I/opt/oracle/rdbms/public -I/opt/oracle/rdbms/demo -I/opt/tmp/ucd-snmp-4.2.2/inclu de -I/opt/tmp/php-4.1.1/ext/xml/expat -DLINUX=22 -DMOD_SSL=208104 -DUSE_HSREGEX -DEAPI -DUSE_EXPAT -I/opt/tmp/php-4.1.1 /TSRM -g -O2 -prefer-pic -o libphp4.la -rpath /opt/tmp/php-4.1.1/libs -avoid-version -L/usr/X11R6/lib -L/usr/local/lib -L/opt/oracle/lib -L/opt/tmp/ucd-snmp-4.2.2/lib -R /usr/X11R6/lib -R /usr/local/lib -R /opt/oracle/lib -R /opt/tmp/ucd -snmp-4.2.2/lib stub.lo Zend/libZend.la sapi/apache/libsapi.la main/libmain.la regex/libregex.la ext/zlib/libzlib.la ex t/gd/libgd.la ext/imap/libimap.la ext/ldap/libldap.la ext/mysql/libmysql.la ext/oci8/liboci8.la ext/openssl/libopenssl.l a ext/pcre/libpcre.la ext/posix/libposix.la ext/session/libsession.la ext/snmp/libsnmp.la ext/standard/libstandard.la ex t/wddx/libwddx.la ext/xml/libxml.la ext/xslt/libxslt.la TSRM/libtsrm.la -lpam -lc-client -ldl -lsablot -lexpat -lsnmp -l m -ldl -lldap -llber -lcrypt -lpam -lgd -lfreetype -lX11 -lXpm -lpng -lz -ljpeg -lz -lcrypt -lssl -lcrypto -lresolv -lm -ldl -lnsl -lresolv -lcrypt -lclntsh /usr/local/lib/libsnmp.a(snmp_client.o): In function `snmp_pdu_create': /opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_client.c:110: multiple definition of `snmp_pdu_create' Zend/.libs/libZend.al(snmp_client.o):/opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_client.c:110: first defined here /usr/local/lib/libsnmp.a(snmp_client.o): In function `snmp_add_null_var': /opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_client.c:140: multiple definition of `snmp_add_null_var' Zend/.libs/libZend.al(snmp_client.o):/opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_client.c:140: first defined here . . . OUTPUT OMITTED . . . /usr/local/lib/libsnmp.a(snmp_alarm.o): In function `alarm_handler': /opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:164: multiple definition of `alarm_handler' Zend/.libs/libZend.al(snmp_alarm.o):/opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:164: first defined here /usr/local/lib/libsnmp.a(snmp_alarm.o): In function `get_next_alarm_delay_time': /opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:170: multiple definition of `get_next_alarm_delay_time' Zend/.libs/libZend.al(snmp_alarm.o):/opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:170: first defined here /usr/local/lib/libsnmp.a(snmp_alarm.o): In function `snmp_alarm_register': /opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:204: multiple definition of `snmp_alarm_register' Zend/.libs/libZend.al(snmp_alarm.o):/opt/tmp/ucd-snmp-4.2.2/snmplib/snmp_alarm.c:204: first defined here collect2: ld returned 1 exit status make[1]: *** [libphp4.la] Error 1 make[1]: Leaving directory `/opt/tmp/php-4.1.1' make: *** [all-recursive] Error 1 Edit this bug report at http://bugs.php.net/?id=14910edit=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] Compilation Bug
Markus, Which header files? I removed all snmp libraries and header files I could find on the system and rebuilt/upgraded ucd-snmp to 4.2.3. Upon make of php, I got the exact same results. Thanks for replying to my message. -Jason Markus Fischer wrote: On Wed, Jan 09, 2002 at 08:17:08AM -0600, Jason Signalness wrote : I'm writing to try to bring attention to a certain bug I've been having. Several people have emailed me asking if I've found a solution to compiling PHP 4.1.1 on Red Hat 7.1 with SNMP support. I have not. The bug is documented here: http://bugs.php.net/bug.php?id=14910 I saw similar bugs in the past, all caused by broken installations or stale header files lying around. Trying cleaning up your system and try again. I've no problems compiling 4.1.1 with ucd-snmp 4.2.3 on debian system. -- Jason Signalness, Systems Administrator Basin Telecommunications, Inc. [EMAIL PROTECTED](701)355-5727 -- -- 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 #14951 Updated: Apache does not start after PHP compile
ID: 14951 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Apache related Operating System: Solaris 2.8 PHP Version: 4.1.1 New Comment: Me too... Same compilation, same error message from Apache. Previous Comments: [2002-01-09 11:36:23] [EMAIL PROTECTED] After succesfull compilation of PHP 4.1.1, Apache failed to start with the following warning: Syntax error on line 222 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: /usr/local/apache/bin/httpd: fatal: relocation error: file /usr/local/apache/libexec/libphp4.so: symbol uncompress: referenced symbol not found My configure line was: ./configure --enable-trans-sid --with-ldap=/usr/local --with-openssl --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql I removed --with-mysql and after recompiling Apache worked fine. The MySQL that I use is 3.23.47. Thanks, Christian. Edit this bug report at http://bugs.php.net/?id=14951edit=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] Bug #14951 Updated: Apache does not start after PHP compile
ID: 14951 Updated by: lobbin Reported By: [EMAIL PROTECTED] Old Status: Open Status: Bogus Bug Type: Apache related Operating System: Solaris 2.8 PHP Version: 4.1.1 New Comment: Bogus http://www.mysql.com/doc/P/H/PHP_problems.html Hint: --with-zlib Previous Comments: [2002-01-09 12:09:28] [EMAIL PROTECTED] Me too... Same compilation, same error message from Apache. [2002-01-09 11:36:23] [EMAIL PROTECTED] After succesfull compilation of PHP 4.1.1, Apache failed to start with the following warning: Syntax error on line 222 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: /usr/local/apache/bin/httpd: fatal: relocation error: file /usr/local/apache/libexec/libphp4.so: symbol uncompress: referenced symbol not found My configure line was: ./configure --enable-trans-sid --with-ldap=/usr/local --with-openssl --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql I removed --with-mysql and after recompiling Apache worked fine. The MySQL that I use is 3.23.47. Thanks, Christian. Edit this bug report at http://bugs.php.net/?id=14951edit=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] Bug #14805 Updated: array_unique works opposed to the manual
ID: 14805 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Arrays related Old Operating System: MS Windows 98 Operating System: MS Windows 98 PWS 4.0 Old PHP Version: 4.0.6 PHP Version: 4.1.1 New Comment: I tested the examples with PHP 4.1.1 on Apache 1.3.9 under debian stable. array_unique() does preserve the *first* key of every related value in this environment. Simone Cortesi [EMAIL PROTECTED] stated on phpdoc list: On my PHP Version 4.0.6 on System Windows 95/98 4.10 (as it reads with phpinfo), I get... what I got, but On the same machine using Cygwin and PHP/4.0.8-dev I get: the expected result (returning with the first keys). Previous Comments: [2002-01-02 13:20:30] [EMAIL PROTECTED] I forgot to mention that there may be something wrong with array_unique itself. There are three values of 3 considered equal in the example above: 2 = 3(string), 4 = 3(int), 5 = 3 (string) [manual] Two elements are considered equal if and only if (string) $elem1 === (string) $elem2. In words: when the string representation is the same. Why does array_unique use the index 4 in this case? (It's neither the first nor the latest key of value 3) [2002-01-02 12:48:29] [EMAIL PROTECTED] The manual (recent version from cvs) states that : array_unique() will keep the first key encountered for every value, and ignore all following keys. I've tested the two examples in this page and I've found this statement is not true. ?php $input = array (4,4,3,4,3,3); $result = array_unique ($input); var_dump($result); ? output: /* PHP 4.0.6 Win'98 PWS */ array(2) { [3]= int(4) [4]= int(3) } but the manual says it should print: array(2) { [0]= int(4) [1]= string(1) 3 } As you can recognize the latest keys are preserved for both value 4 and 3. Edit this bug report at http://bugs.php.net/?id=14805edit=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] Bug #14951 Updated: Apache does not start after PHP compile
ID: 14951 Updated by: mrobinso Reported By: [EMAIL PROTECTED] Status: Bogus Bug Type: Apache related Operating System: Solaris 2.8 PHP Version: 4.1.1 New Comment: This is also in the PHP FAQ: http://www.php.net/manual/en/faq.installation.php#AEN75020 Previous Comments: [2002-01-09 12:20:06] [EMAIL PROTECTED] Bogus http://www.mysql.com/doc/P/H/PHP_problems.html Hint: --with-zlib [2002-01-09 12:09:28] [EMAIL PROTECTED] Me too... Same compilation, same error message from Apache. [2002-01-09 11:36:23] [EMAIL PROTECTED] After succesfull compilation of PHP 4.1.1, Apache failed to start with the following warning: Syntax error on line 222 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/libexec/libphp4.so into server: ld.so.1: /usr/local/apache/bin/httpd: fatal: relocation error: file /usr/local/apache/libexec/libphp4.so: symbol uncompress: referenced symbol not found My configure line was: ./configure --enable-trans-sid --with-ldap=/usr/local --with-openssl --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql I removed --with-mysql and after recompiling Apache worked fine. The MySQL that I use is 3.23.47. Thanks, Christian. Edit this bug report at http://bugs.php.net/?id=14951edit=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] Bug #14952: $_GET and $HTTP_GET_VARS are separate arrays
From: [EMAIL PROTECTED] Operating system: Linux PHP version: 4.1.1 PHP Bug Type: Feature/Change Request Bug description: $_GET and $HTTP_GET_VARS are separate arrays blah.php ?php print_r( $HTTP_GET_VARS ); print_r( $_GET ); echo hr; $_GET['test'] = 1; echo hr; print_r( $HTTP_GET_VARS ); print_r( $_GET ); ? Results from blah.php - Array ( ) Array ( ) Array ( ) Array ( [test] = 1 ) Results from blah.php?test=test - Array ( [test] = test ) Array ( [test] = test ) Array ( [test] = test ) Array ( [test] = 1 ) Aside from the performance/memory implications of having two separate arrays (ie: http://blah.com/blah.php?text=[shakespeare]spell_check=1), it's really annoying when trying to propagate information to a moduralized script which normally takes data off the get-string. Here is my patch: $_GET = $HTTP_GET_VARS; It halves the memory requirements of PHP's default arrays, and behaves much closer to what an end-user would expect. I am willing to bet that NOBODY wants $_GET['blah'] = 'test'; echo $HTTP_GET_VARS['blah']; to fail in mysterious ways. Why is this not done in the first place? I have checked on the mailing lists and in the bug archives, but couldn't find any previous discussion. Send me an email at [EMAIL PROTECTED] if there is a good reason for this, or if I am missing something important. -- Edit bug report at: http://bugs.php.net/?id=14952edit=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] Bug #14953: --without-pear disappeared ?!
From: [EMAIL PROTECTED] Operating system: OpenBSD 3.0 PHP version: 4.1.1 PHP Bug Type: PHP options/info functions Bug description: --without-pear disappeared ?! ./configure --help | more ... --without-pear disable pear ... but if I make ./configure --without-pear ... --without-pear option not valid why ? Also mysql. --with-mysql=/usr/local/lib/mysql PHP still prints out warning, if will use MySQL with other software you should use mysql libs... Bye. -- Edit bug report at: http://bugs.php.net/?id=14953edit=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] Bug #14952 Updated: $_GET and $HTTP_GET_VARS are separate arrays
ID: 14952 Updated by: jan Reported By: [EMAIL PROTECTED] Old Status: Open Status: Bogus Bug Type: Feature/Change Request Operating System: Linux PHP Version: 4.1.1 New Comment: the $_* arrays are intended to be seperate from ther $HTTP_*_VARS arrays. The new arrays are so called super-global. You don't hve to introduce them nito function-scope with global. This is a feature no bug = Bogus Previous Comments: [2002-01-09 12:38:13] [EMAIL PROTECTED] blah.php ?php print_r( $HTTP_GET_VARS ); print_r( $_GET ); echo hr; $_GET['test'] = 1; echo hr; print_r( $HTTP_GET_VARS ); print_r( $_GET ); ? Results from blah.php - Array ( ) Array ( ) Array ( ) Array ( [test] = 1 ) Results from blah.php?test=test - Array ( [test] = test ) Array ( [test] = test ) Array ( [test] = test ) Array ( [test] = 1 ) Aside from the performance/memory implications of having two separate arrays (ie: http://blah.com/blah.php?text=[shakespeare]spell_check=1), it's really annoying when trying to propagate information to a moduralized script which normally takes data off the get-string. Here is my patch: $_GET = $HTTP_GET_VARS; It halves the memory requirements of PHP's default arrays, and behaves much closer to what an end-user would expect. I am willing to bet that NOBODY wants $_GET['blah'] = 'test'; echo $HTTP_GET_VARS['blah']; to fail in mysterious ways. Why is this not done in the first place? I have checked on the mailing lists and in the bug archives, but couldn't find any previous discussion. Send me an email at [EMAIL PROTECTED] if there is a good reason for this, or if I am missing something important. Edit this bug report at http://bugs.php.net/?id=14952edit=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] Building standalone executable and apache module at the same time
I'm working on a PHP RPM, and have run into the problem that I need both a php exectable, and an apache module in the package. My current solution is to run configure and make twice. While this works, I was hoping to find a better solution. Is there any way to get the build system to create both using only one configure/compile? Thanks. Peter -- 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] Building standalone executable and apache module at the same time
Hi, On 09 Jan 2002 12:27:02 -0500 Peter Bowen [EMAIL PROTECTED] wrote: I'm working on a PHP RPM, and have run into the problem that I need both a php exectable, and an apache module in the package. My current solution is to run configure and make twice. While this works, I was hoping to find a better solution. Is there any way to get the build system to create both using only one configure/compile? not for now, but the techies (keep up the good work ;) are working on that. Jan -- Q: Thank Jan? A: http://geschenke.an.dasmoped.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] Building standalone executable and apache module atthe same time
I'm working on a PHP RPM, and have run into the problem that I need both a php exectable, and an apache module in the package. My current solution is to run configure and make twice. While this works, I was hoping to find a better solution. Is there any way to get the build system to create both using only one configure/compile? Not currently, no. -Rasmus -- 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] SOAP and OpenGL stuff
Brad, I have created your CVS account, but please have a look at the existing ext/xmlrpc extension and see what sort of overlap there is with your php_soap extension. ext/xmlrpc has SOAP 1.1 support. And the opengl extension might be a good candidate for PECL (The C extension repository that is part of PEAR). -Rasmus -- 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 #12912 Updated: Call to round() crashes process (DSO only)
ID: 12912 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: Reproducible crash Operating System: Solaris 2.5.1 PHP Version: 4.0.6 New Comment: Yep. Just compiled 4.1.1 and still the same problem. Previous Comments: [2002-01-06 07:39:15] [EMAIL PROTECTED] Does this problem still occur with 4.1.1 and/or the latest CVS? [2001-08-22 17:55:23] [EMAIL PROTECTED] Using Apache 1.3.20, PHP 4.0.6 as a module, on Solaris 2.5.1. Everything else seems to work except the round() function. Any call to round() seg faults the Apache process. Backtrace: #0 0xef7324b4 in _mp_move () #1 0xef7322dc in pow () #2 0xeede8438 in ?? () from /usr/local/apache/libexec/libphp4.so #3 0xeecfe470 in ?? () from /usr/local/apache/libexec/libphp4.so #4 0xeed16abc in ?? () from /usr/local/apache/libexec/libphp4.so #5 0xeed3cc1c in ?? () from /usr/local/apache/libexec/libphp4.so #6 0xeed360b4 in ?? () from /usr/local/apache/libexec/libphp4.so #7 0xeed37494 in ?? () from /usr/local/apache/libexec/libphp4.so #8 0xeed374d8 in ?? () from /usr/local/apache/libexec/libphp4.so #9 0x42ffc in ap_invoke_handler () #10 0x6009c in process_request_internal () #11 0x60120 in ap_process_request () #12 0x536b0 in child_main () #13 0x53944 in make_child () #14 0x53b60 in startup_children () #15 0x54550 in standalone_main () #16 0x5514c in main () The CGI standalone PHP executable, built from the same code, works fine. Edit this bug report at http://bugs.php.net/?id=12912edit=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] Bug #12912 Updated: Call to round() crashes process (DSO only)
ID: 12912 Updated by: derick Reported By: [EMAIL PROTECTED] Old Status: Open Status: Feedback Bug Type: Reproducible crash Operating System: Solaris 2.5.1 PHP Version: 4.0.6 New Comment: Can you make a static apache module, compiled with --enable-debug (non-stripped) and provide a backtrace? Derick Previous Comments: [2002-01-09 16:00:35] [EMAIL PROTECTED] Yep. Just compiled 4.1.1 and still the same problem. [2002-01-06 07:39:15] [EMAIL PROTECTED] Does this problem still occur with 4.1.1 and/or the latest CVS? [2001-08-22 17:55:23] [EMAIL PROTECTED] Using Apache 1.3.20, PHP 4.0.6 as a module, on Solaris 2.5.1. Everything else seems to work except the round() function. Any call to round() seg faults the Apache process. Backtrace: #0 0xef7324b4 in _mp_move () #1 0xef7322dc in pow () #2 0xeede8438 in ?? () from /usr/local/apache/libexec/libphp4.so #3 0xeecfe470 in ?? () from /usr/local/apache/libexec/libphp4.so #4 0xeed16abc in ?? () from /usr/local/apache/libexec/libphp4.so #5 0xeed3cc1c in ?? () from /usr/local/apache/libexec/libphp4.so #6 0xeed360b4 in ?? () from /usr/local/apache/libexec/libphp4.so #7 0xeed37494 in ?? () from /usr/local/apache/libexec/libphp4.so #8 0xeed374d8 in ?? () from /usr/local/apache/libexec/libphp4.so #9 0x42ffc in ap_invoke_handler () #10 0x6009c in process_request_internal () #11 0x60120 in ap_process_request () #12 0x536b0 in child_main () #13 0x53944 in make_child () #14 0x53b60 in startup_children () #15 0x54550 in standalone_main () #16 0x5514c in main () The CGI standalone PHP executable, built from the same code, works fine. Edit this bug report at http://bugs.php.net/?id=12912edit=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] Bogus/Bug #14952 ($_GET != $HTTP_GET_VARS)
I spoke briefly with Jan about the following (imho) mis-feature, who recommended bringing it up on the dev-list. http://bugs.php.net/?id=14952 I ran into the problem (as an end-user) while trying to muck with what the user had passed in (ie: spoof GET data from session-ized defaults if the user did not select anything). Why isn't it: $_GET = $HTTP_GET_VARS? Attached is my understanding of the problem. As it stands right now, I do not want to use $_GET constructs in my code because $_GET is not a drop-in replacement for: $GLOBALS['HTTP_GET_VARS'][...] ...which I assumed it was. No matter where I set a value for $GLOBALS['HTTP_GET_VARS'], it will be the same throughout script execution. With the addition of the $_GET class of variables, there are suddenly two copies of data, two areas to manage in your code. IMHO, it is a bad move for the data to be separated in the long run, especially when there is not a good reason for it. If the world were a perfect place (which it isn't, and I know it ;^) ... I would say that: $_GET = $GLOBALS['HTTP_GET_VARS']; $_POST = $GLOBALS['HTTP_POST_VARS']; $_COOKIE = $GLOBALS['HTTP_COOKIE_VARS']; $_REQUEST = array_merge( $_GET, $_POST, $_COOKIE ); I know that the last request (reference request to the results of a function) isn't really possible or feasible, but the first three definitely are. Another possible solution would be to throw an E_WARNING if $_GET or $GLOBALS['HTTP_GET_VARS'] is used as the left- hand side of an expression. This would make changing information within $_GET or $GLOBALS['HTTP_GET_VARS'] officially frowned upon, which would have alerted me to the fact that now in 4.1.1 there are two places where a GET/POST variable can be named and changed. Or, if $_GET/$HTTP_GET_VARS is detected as a left-hand side expression, call _internal_UPDATE_REQUEST( $key, $value ), to keep all arrays in sync. I wrote up some documentation about the $_* variables, which I would appreciate it if someone more knowledgeable about the inner workings of the $_GET stuff could look over it and let me know if there are any mistakes. I release that documentation to the PHP group under the same terms of license as the rest of PHP's documentation, so please feel free to integrate it if it is a welcome addition. I am not subscribed to this list (am using it through the news gateway now), so I might not receive any responses. I would appreciate being CC'd any relevant discussion. Thanks for everything so far, PHP rocks! :^) --Robert ([EMAIL PROTECTED] / [EMAIL PROTECTED]) Thank you for your response. I understand what the $_* arrays are for, but I still disagree. :^) echo $_GET['blah']; echo $HTTP_GET_VARS['blah']; $HTTP_GET_VARS['blah'] = 'test'; function test() { echo $_GET['blah']; } test(); Why is the array data separate? There is no good reason, and several bad reasons. Good reasons to be separate: 1) You might want $_GET and $H_G_V to be different 2) [some random reason about internal PHP code] 3) does $_REQUEST get updated if $_GET/$_POST is updated too? Bad reasons to be separate: 1) takes twice as much memory 2) $_GET != $HTTP_GET_VARS after script execution begins 3) does $_REQUEST get updated if $_GET/$_POST is updated too? At the very least, this is a documentation bug because $_GET != $HTTP_GET_VARS should be mentioned at http://www.php.net/manual/en/language.variables.predefined.php Here is my stab at documentation for $_* vars. With the introduction of PHP 4.1.1 there are several variables introduced which are guaranteed to be available in every function, no matter what the ini settings are. These variables are: $_GET, $_POST, and $_COOKIE, and contain the same information as their corresponding $HTTP_*_VARS arrays. The other variable introduced is $_REQUEST, which is a merged array of all GET/POST/COOKIE data. SPECIAL NOTE: Although the information contained in $_GET, $_POST, $_COOKIE, and $_REQUEST is initially the same as that found in $HTTP_GET_VARS, $HTTP_POST_VARS, and $HTTP_COOKIE_VARS, changes in one array do not impact changes in any other array. It is considered a bug, hack, or workaround to *set* any value in any of these arrays. (do not use them as a left-hand-side in any expression). This will make your code more readable, more maintainable, and more useful to other script authors. Converting from older styles... === Assume that you have a script which takes a single parameter, 'blah'. In global scope: echo $blah; = echo $_REQUEST['blah']; echo $GLOBALS['blah']; = echo $_REQUEST['blah']; echo $HTTP_GET_VARS['blah'] = echo $_GET['blah']; echo $GLOBALS['HTTP_GET_VARS']['blah'] = echo $_GET['blah']; In function scope: function demonstration() { global $blah, $HTTP_GET_VARS; // 1: using global operator from above echo $blah; // 2: using array HTTP_GET_VARS from global scope echo $HTTP_GET_VARS['blah']; // 3: using no special functions
Re: [PHP-DEV] Bogus/Bug #14952 ($_GET != $HTTP_GET_VARS)
Bad reasons to be separate: 1) takes twice as much memory That's not true due to the shallow copy/copy-on-write nature of things. If you change every element of one array, then yes, at this point you will be taking up twice the memory. -Rasmus -- 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 #10002 Updated: sprintf() and floating point
ID: 10002 Updated by: derick Reported By: [EMAIL PROTECTED] Old Status: Closed Status: Open Bug Type: Strings related Operating System: RedHat 7.0 PHP Version: 4.0 Latest CVS (26/03/2001) Previous Comments: [2001-03-27 12:30:21] [EMAIL PROTECTED] Patch applied, but it's still a strange thing. [2001-03-27 08:32:14] [EMAIL PROTECTED] I can't reproduce it under RH 6.2. Generally the fix isn't supposed to do anything (since arg is a double, 10 should be converted to a double automatically), but the fix can't hurt anything so if it works around a compiler bug, it's fine. PHP cannot use sprintf() because sprintf() works with C types with predefined types for the arguments, whether PHP has its own types, and autoconverts arguments to match the format string. [2001-03-26 17:19:30] [EMAIL PROTECTED] This bug is in 4.0.5RC2 too, just confirmed it [2001-03-26 14:13:27] [EMAIL PROTECTED] ?php printf('%.2f',0.0167332731531132594682276248931884765625); ? produces '0.0:' instead of '0.10' I'm really curious as to why PHP just doesn't use libc's sprintf(). ./configure --with-oracle=/usr/local/oracle/product/8.1.7 \ --with-oci8=/usr/local/oracle/product/8.1.7 --enable-force-cgi-redirect \ --enable-track-vars --with-posix --enable-sockets --enable-sigchild \ --with-gd=/usr/local gcc version 2.95.2 19991024 (release) This is not exactly a fix... --- ext/standard/formatted_print.c Mon Mar 26 14:01:31 2001 +++ ext/standard/formatted_print.c-fixedMon Mar 26 14:02:26 2001 @@ -92,7 +92,7 @@ while (p1 cvt_buf[NDIG]) *p++ = *p1++; } else if (arg 0) { - while ((fj = arg * 10) 1) { + while ((fj = arg * 10.0) 0.999) { arg = fj; r2--; } Edit this bug report at http://bugs.php.net/?id=10002edit=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] Bug #10002 Updated: sprintf() and floating point
ID: 10002 Updated by: gerzson Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Strings related Old Operating System: RedHat 7.0 Operating System: Debian Old PHP Version: 4.0 Latest CVS (26/03/2001) PHP Version: 4.1.1 New Comment: I'd like to reopen it. Visit the page: http://213.134.22.60/~gerzson/sprintf.php Previous Comments: [2002-01-09 16:36:36] [EMAIL PROTECTED] I'm sorry to say that I experienced similar misbehaviour with PHP 4.0.6 and 4.1.1, too. I'm pulling aggregated statistics from database and display it. I'm currently working on minimize a test case, please wait. Till then, visit this link: http://213.134.22.60/~gerzson/sprintf.php this is a very simple test script with a show_source() and phpinfo(). I think this bug should be reopened. [2001-03-27 12:30:21] [EMAIL PROTECTED] Patch applied, but it's still a strange thing. [2001-03-27 08:32:14] [EMAIL PROTECTED] I can't reproduce it under RH 6.2. Generally the fix isn't supposed to do anything (since arg is a double, 10 should be converted to a double automatically), but the fix can't hurt anything so if it works around a compiler bug, it's fine. PHP cannot use sprintf() because sprintf() works with C types with predefined types for the arguments, whether PHP has its own types, and autoconverts arguments to match the format string. [2001-03-26 17:19:30] [EMAIL PROTECTED] This bug is in 4.0.5RC2 too, just confirmed it [2001-03-26 14:13:27] [EMAIL PROTECTED] ?php printf('%.2f',0.0167332731531132594682276248931884765625); ? produces '0.0:' instead of '0.10' I'm really curious as to why PHP just doesn't use libc's sprintf(). ./configure --with-oracle=/usr/local/oracle/product/8.1.7 \ --with-oci8=/usr/local/oracle/product/8.1.7 --enable-force-cgi-redirect \ --enable-track-vars --with-posix --enable-sockets --enable-sigchild \ --with-gd=/usr/local gcc version 2.95.2 19991024 (release) This is not exactly a fix... --- ext/standard/formatted_print.c Mon Mar 26 14:01:31 2001 +++ ext/standard/formatted_print.c-fixedMon Mar 26 14:02:26 2001 @@ -92,7 +92,7 @@ while (p1 cvt_buf[NDIG]) *p++ = *p1++; } else if (arg 0) { - while ((fj = arg * 10) 1) { + while ((fj = arg * 10.0) 0.999) { arg = fj; r2--; } Edit this bug report at http://bugs.php.net/?id=10002edit=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] phpinfo()
I'm having a bit of a problem with phpinfo(). Here is a link to the page http://shawn.phpsecure.com/info.php I'm not sure exactly what its doing but the page code is this ?php phpinfo(); ? This worked just fine until I upgraded to 4.1.0 then 4.1.1 Thanks! ~ Eric
[PHP-DEV] Bug #14819 Updated: str_replace used with serialize
ID: 14819 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: Strings related Operating System: Linux PHP Version: 4.0.5 New Comment: I'm truly sorry. I found that the error was in the database library I was using to take the serialized string and save it in a database, although I'm not clear on why changing the order of operations fixed it (but that's not your job to fix!). Please cancel/close this faulty bug report and chastise me thoroughly. Previous Comments: [2002-01-05 08:05:18] [EMAIL PROTECTED] Cannot reporoduce this: $mystring=don't; $myarray[ 0 ] = s1; $myarray[ 1 ] = s2; $myarray[ 2 ] = str_replace( ', , $mystring ); $myserial = serialize( $myarray ); print $myserial.\n; prints correctly: a:3:{i:0;s:2:s1;i:1;s:2:s2;i:2;s:4:dont;} in PHP 4.0.5, PHP 4.1.1, adn PHP 4.2.0-dev. Does this example work for you? If it does could you please provide a complete example that produces incorrect output. [2002-01-04 20:55:32] [EMAIL PROTECTED] Here are my configuration options: './configure' '--prefix=/usr/local' '--with-apache=/usr/local/src/Apachetoolbox-1.5.19/apache_1.3.19' '--enable-exif' '--enable-memory-limit=yes' '--enable-track-vars' '--with-calendar=shared' '--enable-safe-mode' '--enable-magic-quotes' '--enable-trans-sid' '--enable-wddx' '--enable-ftp' '--with-mysql' '--with-mysql=/usr/local/mysql' '--with-openssl' [2002-01-03 03:56:56] [EMAIL PROTECTED] Status - feedback [2002-01-03 01:28:09] [EMAIL PROTECTED] Just tested it with 4.0.6 and 4.1.0 All seems to be ok. Can you send me your configuration options? [2002-01-02 23:49:09] [EMAIL PROTECTED] Two lines like this: $myarray[ 2 ] = str_replace( ', , $mystring ); $myserial = serialize( $myarray ); produce a serialized array in $myserial but it contains the wrong length or sometimes the wrong value for the string I inserted. It sometimes deletes the ' and the following character, sometimes deletes just the ' but has the wrong length of the string encoded in the serialized variable. An example of $myserial would be: a:3:{i:0;s:2:s1;i:1;s:2:s2;i:2;s:5:dont;} Which encodes the wrong length for the final string. It works correctly when I break it into three lines: $mystring = str_replace( ', , $mystring ); $myarray[ 2 ] = $mystring; $myserial = serialize( $myarray ); An example of $myserial would be: a:3:{i:0;s:2:s1;i:1;s:2:s2;i:2;s:4:dont;} Which encodes the correct length for the final string. This only appears to happen if there is a str_replace match in the string. If there is no match for the str_replace function, the glitch doesn't seem to appear. Thanks. Edit this bug report at http://bugs.php.net/?id=14819edit=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] Bug #14819 Updated: str_replace used with serialize
ID: 14819 Updated by: derick Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Strings related Operating System: Linux PHP Version: 4.0.5 New Comment: user error: bogus Previous Comments: [2002-01-09 16:45:07] [EMAIL PROTECTED] I'm truly sorry. I found that the error was in the database library I was using to take the serialized string and save it in a database, although I'm not clear on why changing the order of operations fixed it (but that's not your job to fix!). Please cancel/close this faulty bug report and chastise me thoroughly. [2002-01-05 08:05:18] [EMAIL PROTECTED] Cannot reporoduce this: $mystring=don't; $myarray[ 0 ] = s1; $myarray[ 1 ] = s2; $myarray[ 2 ] = str_replace( ', , $mystring ); $myserial = serialize( $myarray ); print $myserial.\n; prints correctly: a:3:{i:0;s:2:s1;i:1;s:2:s2;i:2;s:4:dont;} in PHP 4.0.5, PHP 4.1.1, adn PHP 4.2.0-dev. Does this example work for you? If it does could you please provide a complete example that produces incorrect output. [2002-01-04 20:55:32] [EMAIL PROTECTED] Here are my configuration options: './configure' '--prefix=/usr/local' '--with-apache=/usr/local/src/Apachetoolbox-1.5.19/apache_1.3.19' '--enable-exif' '--enable-memory-limit=yes' '--enable-track-vars' '--with-calendar=shared' '--enable-safe-mode' '--enable-magic-quotes' '--enable-trans-sid' '--enable-wddx' '--enable-ftp' '--with-mysql' '--with-mysql=/usr/local/mysql' '--with-openssl' [2002-01-03 03:56:56] [EMAIL PROTECTED] Status - feedback [2002-01-03 01:28:09] [EMAIL PROTECTED] Just tested it with 4.0.6 and 4.1.0 All seems to be ok. Can you send me your configuration options? The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/?id=14819 Edit this bug report at http://bugs.php.net/?id=14819edit=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] Bug #10002 Updated: sprintf() and floating point
ID: 10002 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Closed Bug Type: Strings related Operating System: RedHat 7.0 PHP Version: 4.0 Latest CVS (26/03/2001) New Comment: I'm sorry to say that I experienced similar misbehaviour with PHP 4.0.6 and 4.1.1, too. I'm pulling aggregated statistics from database and display it. I'm currently working on minimize a test case, please wait. Till then, visit this link: http://213.134.22.60/~gerzson/sprintf.php this is a very simple test script with a show_source() and phpinfo(). I think this bug should be reopened. Previous Comments: [2001-03-27 12:30:21] [EMAIL PROTECTED] Patch applied, but it's still a strange thing. [2001-03-27 08:32:14] [EMAIL PROTECTED] I can't reproduce it under RH 6.2. Generally the fix isn't supposed to do anything (since arg is a double, 10 should be converted to a double automatically), but the fix can't hurt anything so if it works around a compiler bug, it's fine. PHP cannot use sprintf() because sprintf() works with C types with predefined types for the arguments, whether PHP has its own types, and autoconverts arguments to match the format string. [2001-03-26 17:19:30] [EMAIL PROTECTED] This bug is in 4.0.5RC2 too, just confirmed it [2001-03-26 14:13:27] [EMAIL PROTECTED] ?php printf('%.2f',0.0167332731531132594682276248931884765625); ? produces '0.0:' instead of '0.10' I'm really curious as to why PHP just doesn't use libc's sprintf(). ./configure --with-oracle=/usr/local/oracle/product/8.1.7 \ --with-oci8=/usr/local/oracle/product/8.1.7 --enable-force-cgi-redirect \ --enable-track-vars --with-posix --enable-sockets --enable-sigchild \ --with-gd=/usr/local gcc version 2.95.2 19991024 (release) This is not exactly a fix... --- ext/standard/formatted_print.c Mon Mar 26 14:01:31 2001 +++ ext/standard/formatted_print.c-fixedMon Mar 26 14:02:26 2001 @@ -92,7 +92,7 @@ while (p1 cvt_buf[NDIG]) *p++ = *p1++; } else if (arg 0) { - while ((fj = arg * 10) 1) { + while ((fj = arg * 10.0) 0.999) { arg = fj; r2--; } Edit this bug report at http://bugs.php.net/?id=10002edit=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] Bug #14954: Warning: Server Error with mail() function
From: [EMAIL PROTECTED] Operating system: Windows 2000 PHP version: 4.1.0 PHP Bug Type: Mail related Bug description: Warning: Server Error with mail() function The mail() function doesn't work properly. Every so often it does send mail. I tried putting the php.ini in the c:\php\php.ini instead of the c:\winnt\php.ini but that didn't help. I've been at it a while and I've found no solutions on the web yet, while other people have encountered the same issue. PHP.INI has a valid SMTP = mail.pnang.com and sendmail_from = [EMAIL PROTECTED] The code mail([EMAIL PROTECTED], My Subject, Line 1\nLine 2\nLine 3); And the birthday one from the manual. Again the frustrating part is it worked last night. My outlook works perfectly with the same SMTP. Thanks, Jonathan -- Edit bug report at: http://bugs.php.net/?id=14954edit=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] Bug #12912 Updated: Call to round() crashes process (DSO only)
ID: 12912 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Old Status: Feedback Status: Open Bug Type: Reproducible crash Operating System: Solaris 2.5.1 Old PHP Version: 4.0.6 PHP Version: 4.1.1 New Comment: Here you go: #0 0xef1b7be0 in zif_get_defined_vars (ht=980160, return_value=0x, this_ptr=0x, return_value_used=0) at zend_builtin_functions.c:916 #1 0x47380 in ap_clear_pool () #2 0x47410 in ap_destroy_pool () #3 0x47368 in ap_clear_pool () #4 0x47410 in ap_destroy_pool () #5 0x5c354 in clean_parent_exit () #6 0x60188 in standalone_main () #7 0x60968 in main () Previous Comments: [2002-01-09 16:05:16] [EMAIL PROTECTED] Can you make a static apache module, compiled with --enable-debug (non-stripped) and provide a backtrace? Derick [2002-01-09 16:00:35] [EMAIL PROTECTED] Yep. Just compiled 4.1.1 and still the same problem. [2002-01-06 07:39:15] [EMAIL PROTECTED] Does this problem still occur with 4.1.1 and/or the latest CVS? [2001-08-22 17:55:23] [EMAIL PROTECTED] Using Apache 1.3.20, PHP 4.0.6 as a module, on Solaris 2.5.1. Everything else seems to work except the round() function. Any call to round() seg faults the Apache process. Backtrace: #0 0xef7324b4 in _mp_move () #1 0xef7322dc in pow () #2 0xeede8438 in ?? () from /usr/local/apache/libexec/libphp4.so #3 0xeecfe470 in ?? () from /usr/local/apache/libexec/libphp4.so #4 0xeed16abc in ?? () from /usr/local/apache/libexec/libphp4.so #5 0xeed3cc1c in ?? () from /usr/local/apache/libexec/libphp4.so #6 0xeed360b4 in ?? () from /usr/local/apache/libexec/libphp4.so #7 0xeed37494 in ?? () from /usr/local/apache/libexec/libphp4.so #8 0xeed374d8 in ?? () from /usr/local/apache/libexec/libphp4.so #9 0x42ffc in ap_invoke_handler () #10 0x6009c in process_request_internal () #11 0x60120 in ap_process_request () #12 0x536b0 in child_main () #13 0x53944 in make_child () #14 0x53b60 in startup_children () #15 0x54550 in standalone_main () #16 0x5514c in main () The CGI standalone PHP executable, built from the same code, works fine. Edit this bug report at http://bugs.php.net/?id=12912edit=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] Bug #14954 Updated: Warning: Server Error with mail() function
ID: 14954 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Mail related Operating System: Windows 2000 PHP Version: 4.1.0 New Comment: While I get a Warning: Server Error in c:\wwwapache\suddenserv\test_email.php on line 7 when the SMTP = mail.pnang.com when I change the SMTP = mail.pnang.comx I get Warning: Failed to Connect in c:\wwwapache\suddenserv\test_email.php on line 7 Previous Comments: [2002-01-09 17:10:07] [EMAIL PROTECTED] The mail() function doesn't work properly. Every so often it does send mail. I tried putting the php.ini in the c:\php\php.ini instead of the c:\winnt\php.ini but that didn't help. I've been at it a while and I've found no solutions on the web yet, while other people have encountered the same issue. PHP.INI has a valid SMTP = mail.pnang.com and sendmail_from = [EMAIL PROTECTED] The code mail([EMAIL PROTECTED], My Subject, Line 1\nLine 2\nLine 3); And the birthday one from the manual. Again the frustrating part is it worked last night. My outlook works perfectly with the same SMTP. Thanks, Jonathan Edit this bug report at http://bugs.php.net/?id=14954edit=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] Bug #13486 Updated: Apache/PHP hangs
ID: 13486 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Closed Bug Type: Scripting Engine problem Operating System: SunOS 5.8 PHP Version: 4.0.6 New Comment: Same here with 4.1.1 and Apache 1.3.22 on Windows 2000. Previous Comments: [2002-01-05 16:48:23] [EMAIL PROTECTED] No feedback. Closing. [2001-12-14 13:50:48] [EMAIL PROTECTED] Could you try 4.1.0 and reoprt the result? [2001-09-28 14:55:21] [EMAIL PROTECTED] Hello, I got a weird problem here -- Apache (1.3.20) + PHP 4.06 hangs. No core dump, no log entries -- just hangs. Request to ANY php file produces no results (not even headers returned), however request to .html files work just fine -- which leads me to beleave that this might be PHP related issue. Apache restart fixes the problem. This issue happened couple times... Today I was able to reproduce it by running ./ab -n 1 -c 10 http:.../index.php The third time i ran this, PHP stopped responding. Because there are no core dumps, nor log file entries, the only thing I could do was to runn truss on apache process. PHP was compiled with the following options: ./configure --disable-debug --with-mysql=/usr/local/mysql --enable-track-vars --disable-display-source --enable-memory-limit --with-apxs=/usr/local/etc/apache/bin/apxs index.php is a very simple script: ?php require(header.inc); ? BPlease enter your query:/B form name=searchform action=http://search.symbol.com/search.php; method=get onSubmit=this.search.value=this.search.value.toLowerCase();return true input type=text name=search value= input type=submit value=Search /form Below is output of truss on both /test.html and /index.php (same pid)... It seems that /index.php request gets Err#25 ENOTTY Any idea why this is happening? Any suggestions on how to fix this are very much appreciated. Please let me know if there is any more info I can provide. Is it a know issue with Sun? I could not find similar posts on bugs.php.net... --- TRUSS for /index.php fcntl(18, F_SETLKW, 0x000E5410) (sleeping...) fcntl(18, F_SETLKW, 0x000E5410) = 0 accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) (sleeping...) accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) = 3 fcntl(18, F_SETLKW, 0x000E5434) = 0 sigaction(SIGUSR1, 0xFFBEF670, 0xFFBEF6F0) = 0 getsockname(3, 0xFFBEF7C8, 0xFFBEF7DC, 1) = 0 setsockopt(3, 6, 1, 0xFFBEF72C, 4, 1) = 0 read(3, G E T / i n d e x . p.., 4096) = 92 sigaction(SIGUSR1, 0xFFBED568, 0xFFBED5E8) = 0 time() = 1001694729 stat(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, 0x0012E958) = 0 umask(077) = 022 umask(022) = 077 setitimer(ITIMER_PROF, 0xFFBEF390, 0x) = 0 sigaction(SIGPROF, 0xFFBEF260, 0xFFBEF2E0) = 0 sigprocmask(SIG_UNBLOCK, 0xFFBEF380, 0x) = 0 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBEE278)= 0 stat64(/, 0xFFBEE1E0) = 0 open64(./../, O_RDONLY|O_NDELAY) = 5 fcntl(5, F_SETFD, 0x0001) = 0 fstat64(5, 0xFFBECC00) = 0 fstat64(5, 0xFFBEE278) = 0 close(5)= 0 chdir(/usr/local/etc/apache/htdocs/search.symbol.com) = 0 open(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, O_RDONLY) = 5 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBED5B0)= 0 stat64(/, 0xFFBED518) = 0 open64(./../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 128 close(6)= 0 open64(./../../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 384 close(6)= 0 open64(./../../../, O_RDONLY|O_NDELAY)= 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 112 close(6)= 0 open64(./../../../../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001)
[PHP-DEV] Re: Bug #14930 Updated: CLI header suppression problems
Here's what I can tell so far: the arguments do get passed to cgi_main.c's main() function just fine, and the arguments are even parsed okay. The problem seems to occur because when the arguments are parsed from a script like so: #!/usr/bin/php -c /path/to/ini/file ?php ... ? it seems that there's at least one leading space in the argument to the -c option, i.e. in sapi/cgi/cgi_main.c, cgi_sapi_module.php_ini_path_override is set to /path/to/ini/file instead of /path/to/ini/file. This in turn ends up confusing php_init_config() in main/php_ini.c, and although it will return SUCCESS (as the file isn't found thanks to the leading spaces), which is okay because the defaults are used instead, and no warning or error is given about not being able to find php.ini in /path/to/ini/file. I didn't catch this until about an hour ago, but all of my CLI PHP scripts were relying on default settings rather than the ones I had set in /usr/local/zend/etc/cli/php.ini, or as far as php_init_config() was concerned, said file with a leading space. A quick fix for the problem would be to trim off those leading spaces to the argument to -c, but I'm not sure if that wouldn't cause more problems in the long run. For instance, is it possible to have leading spaces in directory names on some operating systems? It's not a problem for me, and it probably wouldn't be a huge problem overall, but if there's a chance guaranteed it will affect somebody. Anyways, quick solution, very in-elegant and probably not very safe (but it worked, so at least it proves I'm somewhat right on this) was to stick the following bit of code (my additions prefixed with ): if (php_ini_path_override) { php_ini_search_path = php_ini_path_override; while (php_ini_search_path[0] == ' ') { for (i = 0; i strlen(php_ini_search_path); i++) { php_ini_search_path[i] = php_ini_search_path[i + 1]; } } free_ini_search_path = 0; } in main/php_ini.c. Strips out the leading spaces and lets my scripts work properly again, with the proper php.ini settings. Comments? J [EMAIL PROTECTED] wrote: ID: 14930 Updated by: edink Reported By: [EMAIL PROTECTED] Old Status: Open Status: Analyzed Bug Type: Output Control Operating System: linux 2.4.9 PHP Version: 4.1.1 New Comment: I was able to reproduce this. However it does not appear to be a php bug. Most likely a glibc bug. If I put this line on top of my script: #!/usr/bin/php -q -c /path/to/ini/file -C the following values get passed to php's main() function. argc=3 argv[0]: php argv[1]: -q -c /path/to/ini/file -C argv[2]: ./test (which is the name of the script) With parameters passed like that, php has no chance of passing them correctly. FreeBSD systems appear to be free of this problem. Previous Comments: Edit this bug report at http://bugs.php.net/?id=14930edit=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] Bug #14955: php chrashes if i use some session functions
From: [EMAIL PROTECTED] Operating system: WinXP PHP version: 4.1.1 PHP Bug Type: Reproducible crash Bug description: php chrashes if i use some session functions OS: WinXP PHP: 4.1.1 Apache: neweste stable windows version I tryed 5 things now: ### first ### $id = 143445254; session_id($id); session_start(); ### second ### session_register(count); $count++; ### third ### $s_permission = false; @session_start(); session_register(s_permission); $fallback = session_name().=.session_id(); ### fourth ### session_start(); ### fifth ### session_register(); All everytime PHP.exe crashes (AppName: php.exeAppVer: 0.0.0.0 ModName: php4ts.dll ModVer: 0.0.0.0 Offset: 000a956c) What the hell is the problem? ### php.ini ### [Session] ; Handler used to store/retrieve data. session.save_handler = files ; Argument passed to save_handler. In the case of files, this is the path ; where data files are stored. Note: Windows users have to change this ; variable in order to use PHP's session functions. session.save_path = /tmp ; Whether to use cookies. session.use_cookies = 1 ; Name of the session (used as cookie name). session.name = PHPSESSID ; Initialize session on request startup. session.auto_start = 0 ; Lifetime in seconds of cookie or, if 0, until browser is restarted. session.cookie_lifetime = 0 ; The path for which the cookie is valid. session.cookie_path = / ; The domain for which the cookie is valid. session.cookie_domain = ; Handler used to serialize data. php is the standard serializer of PHP. session.serialize_handler = php ; Percentual probability that the 'garbage collection' process is started ; on every session initialization. session.gc_probability = 1 ; After this number of seconds, stored data will be seen as 'garbage' and ; cleaned up by the garbage collection process. session.gc_maxlifetime = 1440 ; Check HTTP Referer to invalidate externally stored URLs containing ids. session.referer_check = ; How many bytes to read from the file. session.entropy_length = 0 ; Specified here to create the session id. session.entropy_file = ;session.entropy_length = 16 ;session.entropy_file = /dev/urandom ; Set to {nocache,private,public} to determine HTTP caching aspects. session.cache_limiter = nocache ; Document expires after n minutes. session.cache_expire = 180 ; use transient sid support if enabled by compiling with --enable-trans-sid. session.use_trans_sid = 1 url_rewriter.tags = a=href,area=href,frame=src,input=src,form=fakeentry ### apache config, php stuff ### # And for PHP 4.x, use: # ScriptAlias /php/ C:/server/httpd/php/ AddType application/x-httpd-php .php AddType application/x-httpd-php .php3 AddType application/x-httpd-php .php4 AddType application/x-httpd-php .phtml Action application/x-httpd-php /php/php.exe AddType application/x-tar .tgz ### apache error log ### [Thu Jan 10 00:26:04 2002] [error] [client 127.0.0.1] Premature end of script headers: c:/server/httpd/php/php.exe Anyone can help me plz??? -- Edit bug report at: http://bugs.php.net/?id=14955edit=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] Bug #13345 Updated: PHP hangs
ID: 13345 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: IIS related Operating System: Windows Advanced Server PHP Version: 4.0.6 New Comment: Same here with 4.1.1 and Apache 1.3.22 on Windows 2000. If I stop the transfer the php.exe process still runs as an Apache child and you cannot kill it. Running the same script on the command line works always. Note that my script uses odbc. Previous Comments: [2001-09-17 09:53:40] [EMAIL PROTECTED] I have installed sucessfully PHP 4.0.6 on my Windows Advanced Server with IIS 5.0. And I have tested the phpinfo() several times however everynow and then when I try to access the page or any other php page on the server, it hangs and the browser keeps on saying trying to connect. I've tried to reboot the webserver ( :( ) several times and it works first then it hangs again. I really need to know what is going on here since I wanna host some php sites for clients and it is not a good idea at all to reboot a webserver every day. Thank you, Wissam Edit this bug report at http://bugs.php.net/?id=13345edit=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: CVS Account Request: iliaa
Ilia A. wrote: Maintain the SHMOP module. Your email address sounds bogus email address. Could you use other address? -- Yasuo Ohgaki -- 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] cancel of 20020109232659.31293.qmail@pb1.pair.com
cancel by original author -- 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] cancel of 20020109232659.31293.qmail@pb1.pair.com
cancel by original author -- 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: CVS Account Request: iliaa
You can use [EMAIL PROTECTED], [EMAIL PROTECTED] is the account that is subcribed to the php mailing list, which is why I use it. Sorry 'bout the confusion. Ilia On January 9, 2002 06:31 pm, Yasuo Ohgaki wrote: Ilia A. wrote: Maintain the SHMOP module. Your email address sounds bogus email address. Could you use other address? -- 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: Bug #14930 Updated: CLI header suppression problems
Ack, didn't mean to hit that send button yet! I wrote this while experimenting, and it seems that just when I thought I had it, I didn't, of course, but I sent this to the list anyways, accidentally. At first I thought I was golden, because my little fix did work... so long as you didn't have anything after your -c argument. Of course, try doing something like this: #!/usr/local/bin/php -c /some/path -q And your script dies, or at least it can't find the php.ini file, because it thinks that the path should be -c /some/path -q. Argh. Let me get back on this in a bit, I'll fix it next time, really. J J Smith wrote: Here's what I can tell so far: the arguments do get passed to cgi_main.c's main() function just fine, and the arguments are even parsed okay. The problem seems to occur because when the arguments are parsed from a script like so: #!/usr/bin/php -c /path/to/ini/file ?php ... ? it seems that there's at least one leading space in the argument to the -c option, i.e. in sapi/cgi/cgi_main.c, cgi_sapi_module.php_ini_path_override is set to /path/to/ini/file instead of /path/to/ini/file. This in turn ends up confusing php_init_config() in main/php_ini.c, and although it will return SUCCESS (as the file isn't found thanks to the leading spaces), which is okay because the defaults are used instead, and no warning or error is given about not being able to find php.ini in /path/to/ini/file. I didn't catch this until about an hour ago, but all of my CLI PHP scripts were relying on default settings rather than the ones I had set in /usr/local/zend/etc/cli/php.ini, or as far as php_init_config() was concerned, said file with a leading space. A quick fix for the problem would be to trim off those leading spaces to the argument to -c, but I'm not sure if that wouldn't cause more problems in the long run. For instance, is it possible to have leading spaces in directory names on some operating systems? It's not a problem for me, and it probably wouldn't be a huge problem overall, but if there's a chance guaranteed it will affect somebody. Anyways, quick solution, very in-elegant and probably not very safe (but it worked, so at least it proves I'm somewhat right on this) was to stick the following bit of code (my additions prefixed with ): if (php_ini_path_override) { php_ini_search_path = php_ini_path_override; while (php_ini_search_path[0] == ' ') { for (i = 0; i strlen(php_ini_search_path); i++) { php_ini_search_path[i] = php_ini_search_path[i + 1]; } } free_ini_search_path = 0; } in main/php_ini.c. Strips out the leading spaces and lets my scripts work properly again, with the proper php.ini settings. Comments? J -- 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-CVS] cvs: php4 /ext/standard array.c /ext/standard/tests/array count_recursive.phpt
Sterling Hughes wrote: Hmm sounds a bit weird to me but if it's really useful than it's OK :) I have to agree, and its really not that hard to implement in user space:: function count_recursive($ar) { $total = 0; foreach ($ar as $e = $val) { if (is_array($val)) { $total += count_recursive($val); } else { $total++; } } return $total; } To me its seems like YACFA (Yet another confusing function argument). -Sterling It's not hard, but it could be very *slow*... Loop and function call in PHP script is slow in general :) Since it's a O(n), so it may be okay to be slow, though. -- Yasuo Ohgaki Andi At 06:54 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Why is this useful? To count the nodes in a tree: $ar = array ( child1 = array (child2, child3, child4), child5 = array (child6, child7, child8) ); (maybe a louzy example, but you should get the idea :) Derick At 06:50 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Was this in 4.1.1? No, only on the 4.2.0 branch. Derick At 06:49 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Isn't this the function we decided to nuke? Nope, that was is_array_multidimensional(). I'll check if it's nuked, is not, I'll nuke it. Derick Andi At 04:03 PM 1/9/2002 +, Derick Rethans wrote: derick Wed Jan 9 11:03:36 2002 EDT Modified files: /php4/ext/standard array.c /php4/ext/standard/tests/array count_recursive.phpt Log: - Fix bug introduced in earlier patch Index: php4/ext/standard/array.c diff -u php4/ext/standard/array.c:1.151 php4/ext/standard/array.c:1.152 --- php4/ext/standard/array.c:1.151 Sat Dec 29 15:59:59 2001 +++ php4/ext/standard/array.c Wed Jan 9 11:03:34 2002 @@ -21,7 +21,7 @@ +--+ */ -/* $Id: array.c,v 1.151 2001/12/29 20:59:59 derick Exp $ */ +/* $Id: array.c,v 1.152 2002/01/09 16:03:34 derick Exp $ */ #include php.h #include php_ini.h @@ -260,11 +260,16 @@ if (zend_parse_parameters (ZEND_NUM_ARGS() TSRMLS_CC, z|l, array, mode) == FAILURE) return; - if (Z_TYPE_P(array) == IS_ARRAY) { - RETURN_LONG (php_count_recursive (array, mode)); - } else { - /* return 1 for non-array arguments */ - RETURN_LONG(1); + switch (Z_TYPE_P(array)) { + case IS_NULL: + RETURN_LONG(0); + break; + case IS_ARRAY: + RETURN_LONG (php_count_recursive (array, mode)); + break; + default: + RETURN_LONG(1); + break; } } /* }}} */ Index: php4/ext/standard/tests/array/count_recursive.phpt diff -u php4/ext/standard/tests/array/count_recursive.phpt:1.1 php4/ext/standard/tests/array/count_recursive.phpt:1.2 --- php4/ext/standard/tests/array/count_recursive.phpt:1.1 Sat Dec 29 16:05:03 2001 +++ php4/ext/standard/tests/array/count_recursive.phpt Wed Jan 9 11:03:36 2002 @@ -4,6 +4,11 @@ --GET-- --FILE-- ?php +print Testing NULL...\n; +$arr = NULL; +print COUNT_NORMAL: should be 0, is .count($arr, COUNT_NORMAL).\n; +print COUNT_RECURSIVE: should be 0, is .count($arr, COUNT_RECURSIVE).\n; + print Testing arrays...\n; $arr = array(1, array(3, 4, array(6, array(8; print COUNT_NORMAL: should be 2, is .count($arr, COUNT_NORMAL).\n; @@ -23,6 +28,9 @@ print COUNT_NORMAL: should be 2, is .count(array(a, array(b))).\n; ? --EXPECT-- +Testing NULL... +COUNT_NORMAL: should be 0, is 0 +COUNT_RECURSIVE: should be 0, is 0 Testing arrays... COUNT_NORMAL: should be 2, is 2 COUNT_RECURSIVE: should be 8, is 8 -- PHP CVS 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 CVS 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 CVS 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 CVS 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 CVS Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list
Re: [PHP-DEV] Re: [PHP-CVS] cvs: php4 /ext/standard array.c /ext/standard/tests/array count_recursive.phpt
Sterling Hughes wrote: Hmm sounds a bit weird to me but if it's really useful than it's OK :) I have to agree, and its really not that hard to implement in user space:: function count_recursive($ar) { $total = 0; foreach ($ar as $e = $val) { if (is_array($val)) { $total += count_recursive($val); } else { $total++; } } return $total; } To me its seems like YACFA (Yet another confusing function argument). -Sterling It's not hard, but it could be very *slow*... Loop and function call in PHP script is slow in general :) Since it's a O(n), so it may be okay to be slow, though. Well, yeah, but then let's just make PHP a templating engine and write all our logic in C C++!! PHP has evolved to the point where I think its ok to code a majority of the business logic in PHP instead of C. A performance critical script wouldn't do a recursive count anyhow, it just wouldn't make sense. -Sterling -- Yasuo Ohgaki Andi At 06:54 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Why is this useful? To count the nodes in a tree: $ar = array ( child1 = array (child2, child3, child4), child5 = array (child6, child7, child8) ); (maybe a louzy example, but you should get the idea :) Derick At 06:50 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Was this in 4.1.1? No, only on the 4.2.0 branch. Derick At 06:49 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Isn't this the function we decided to nuke? Nope, that was is_array_multidimensional(). I'll check if it's nuked, is not, I'll nuke it. Derick Andi At 04:03 PM 1/9/2002 +, Derick Rethans wrote: derick Wed Jan 9 11:03:36 2002 EDT Modified files: /php4/ext/standard array.c /php4/ext/standard/tests/array count_recursive.phpt Log: - Fix bug introduced in earlier patch Index: php4/ext/standard/array.c diff -u php4/ext/standard/array.c:1.151 php4/ext/standard/array.c:1.152 --- php4/ext/standard/array.c:1.151 Sat Dec 29 15:59:59 2001 +++ php4/ext/standard/array.c Wed Jan 9 11:03:34 2002 @@ -21,7 +21,7 @@ +--+ */ -/* $Id: array.c,v 1.151 2001/12/29 20:59:59 derick Exp $ */ +/* $Id: array.c,v 1.152 2002/01/09 16:03:34 derick Exp $ */ #include php.h #include php_ini.h @@ -260,11 +260,16 @@ if (zend_parse_parameters (ZEND_NUM_ARGS() TSRMLS_CC, z|l, array, mode) == FAILURE) return; - if (Z_TYPE_P(array) == IS_ARRAY) { - RETURN_LONG (php_count_recursive (array, mode)); - } else { - /* return 1 for non-array arguments */ - RETURN_LONG(1); + switch (Z_TYPE_P(array)) { + case IS_NULL: + RETURN_LONG(0); + break; + case IS_ARRAY: + RETURN_LONG (php_count_recursive (array, mode)); + break; + default: + RETURN_LONG(1); + break; } } /* }}} */ Index: php4/ext/standard/tests/array/count_recursive.phpt diff -u php4/ext/standard/tests/array/count_recursive.phpt:1.1 php4/ext/standard/tests/array/count_recursive.phpt:1.2 --- php4/ext/standard/tests/array/count_recursive.phpt:1.1 Sat Dec 29 16:05:03 2001 +++ php4/ext/standard/tests/array/count_recursive.phpt Wed Jan 9 11:03:36 2002 @@ -4,6 +4,11 @@ --GET-- --FILE-- ?php +print Testing NULL...\n; +$arr = NULL; +print COUNT_NORMAL: should be 0, is .count($arr, COUNT_NORMAL).\n; +print COUNT_RECURSIVE: should be 0, is .count($arr, COUNT_RECURSIVE).\n; + print Testing arrays...\n; $arr = array(1, array(3, 4, array(6, array(8; print COUNT_NORMAL: should be 2, is .count($arr, COUNT_NORMAL).\n; @@ -23,6 +28,9 @@ print COUNT_NORMAL: should be 2, is .count(array(a, array(b))).\n; ? --EXPECT-- +Testing NULL... +COUNT_NORMAL: should be 0, is 0 +COUNT_RECURSIVE: should be 0, is 0 Testing arrays... COUNT_NORMAL: should be 2, is 2 COUNT_RECURSIVE: should be 8, is 8 -- PHP CVS 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 CVS 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 CVS Mailing List (http://www.php.net/) To
[PHP-DEV] Bug #14956: --with-imap-ssl hand apache start with libssl.so
From: [EMAIL PROTECTED] Operating system: redhat 7.1 PHP version: 4.1.1 PHP Bug Type: Apache related Bug description: --with-imap-ssl hand apache start with libssl.so after compiling php 4.11 all in done correctly as I start httpd it runs as I statt httpd with libssl.so it hangs (do not start) config file : ./configure --with-apxs=/usr/local/psa/apache/bin/apxs --prefix=/usr/local/psa/apache --with-system-regex --with-config-file-path=/usr/local/psa/apache/conf --disable-debug --disable-pear --enable-sockets --enable-track-vars --with-gd --with-mysql=/usr/local/psa/mysql --with-imap --with-kerberos --with-pam --with-imap-ssl -- Edit bug report at: http://bugs.php.net/?id=14956edit=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] Re: CVS Account Request: iliaa
I've sent one on Jan. 2, 2002 it appeared on the php-dev list. Here is the copy of the message, just in case. [PHP-DEV] CVS Account Request: iliaa Date: Wed, 2 Jan 2002 19:15:46 -0500 From: Ilia A. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Reply to: [EMAIL PROTECTED] Maintain the SHMOP module. -- 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] Ilia On January 9, 2002 07:00 pm, you wrote: I don't see a cvs account request from him On Thu, 10 Jan 2002, Yasuo Ohgaki wrote: Prottoss wrote: You can use [EMAIL PROTECTED], [EMAIL PROTECTED] is the account that is subcribed to the php mailing list, which is why I use it. Sorry 'bout the confusion. Ilia On January 9, 2002 06:31 pm, Yasuo Ohgaki wrote: Ilia A. wrote: Maintain the SHMOP module. Your email address sounds bogus email address. Could you use other address? Hi all karma granters :) He(she?) is one of author of SHMOP module and willing to maintain the module. Currently, no maintainer is listed under EXTENSIONS file. I think he should have CVS access for ext/shmop and phpdoc at least. Anyone could give karma? Thank you. -- 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: [PHP-CVS] cvs: php4 /ext/standard array.c /ext/standard/tests/array count_recursive.phpt
Sterling Hughes wrote: Sterling Hughes wrote: Hmm sounds a bit weird to me but if it's really useful than it's OK :) I have to agree, and its really not that hard to implement in user space:: function count_recursive($ar) { $total = 0; foreach ($ar as $e = $val) { if (is_array($val)) { $total += count_recursive($val); } else { $total++; } } return $total; } To me its seems like YACFA (Yet another confusing function argument). Forgot to read this line :) PECL array module? -Sterling It's not hard, but it could be very *slow*... Loop and function call in PHP script is slow in general :) Since it's a O(n), so it may be okay to be slow, though. Well, yeah, but then let's just make PHP a templating engine and write all our logic in C C++!! PHP has evolved to the point where I think its ok to code a majority of the business logic in PHP instead of C. A performance critical script wouldn't do a recursive count anyhow, it just wouldn't make sense. -Sterling I agree. However some users want to count huge array with PHP. I cannot believe there are users use more than 100MB array, but there are. Anyway, I would like to see better performance for loops by default. (performance with ZendOptimizer) It helps array operations a lot. I vote 0 for this function ;) -- Yasuo Ohgaki -- Yasuo Ohgaki Andi At 06:54 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Why is this useful? To count the nodes in a tree: $ar = array ( child1 = array (child2, child3, child4), child5 = array (child6, child7, child8) ); (maybe a louzy example, but you should get the idea :) Derick At 06:50 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Was this in 4.1.1? No, only on the 4.2.0 branch. Derick At 06:49 PM 1/9/2002 +0100, [EMAIL PROTECTED] wrote: On Wed, 9 Jan 2002, Andi Gutmans wrote: Isn't this the function we decided to nuke? Nope, that was is_array_multidimensional(). I'll check if it's nuked, is not, I'll nuke it. Derick Andi At 04:03 PM 1/9/2002 +, Derick Rethans wrote: derick Wed Jan 9 11:03:36 2002 EDT Modified files: /php4/ext/standard array.c /php4/ext/standard/tests/array count_recursive.phpt Log: - Fix bug introduced in earlier patch Index: php4/ext/standard/array.c diff -u php4/ext/standard/array.c:1.151 php4/ext/standard/array.c:1.152 --- php4/ext/standard/array.c:1.151 Sat Dec 29 15:59:59 2001 +++ php4/ext/standard/array.c Wed Jan 9 11:03:34 2002 @@ -21,7 +21,7 @@ +--+ */ -/* $Id: array.c,v 1.151 2001/12/29 20:59:59 derick Exp $ */ +/* $Id: array.c,v 1.152 2002/01/09 16:03:34 derick Exp $ */ #include php.h #include php_ini.h @@ -260,11 +260,16 @@ if (zend_parse_parameters (ZEND_NUM_ARGS() TSRMLS_CC, z|l, array, mode) == FAILURE) return; - if (Z_TYPE_P(array) == IS_ARRAY) { - RETURN_LONG (php_count_recursive (array, mode)); - } else { - /* return 1 for non-array arguments */ - RETURN_LONG(1); + switch (Z_TYPE_P(array)) { + case IS_NULL: + RETURN_LONG(0); + break; + case IS_ARRAY: + RETURN_LONG (php_count_recursive (array, mode)); + break; + default: + RETURN_LONG(1); + break; } } /* }}} */ Index: php4/ext/standard/tests/array/count_recursive.phpt diff -u php4/ext/standard/tests/array/count_recursive.phpt:1.1 php4/ext/standard/tests/array/count_recursive.phpt:1.2 --- php4/ext/standard/tests/array/count_recursive.phpt:1.1 Sat Dec 29 16:05:03 2001 +++ php4/ext/standard/tests/array/count_recursive.phpt Wed Jan 9 11:03:36 2002 @@ -4,6 +4,11 @@ --GET-- --FILE-- ?php +print Testing NULL...\n; +$arr = NULL; +print COUNT_NORMAL: should be 0, is .count($arr, COUNT_NORMAL).\n; +print COUNT_RECURSIVE: should be 0, is .count($arr, COUNT_RECURSIVE).\n; + print Testing arrays...\n; $arr = array(1, array(3, 4, array(6, array(8; print COUNT_NORMAL: should be 2, is .count($arr, COUNT_NORMAL).\n; @@ -23,6 +28,9 @@ print COUNT_NORMAL: should be 2, is .count(array(a, array(b))).\n; ? --EXPECT-- +Testing NULL... +COUNT_NORMAL: should be 0, is 0 +COUNT_RECURSIVE: should be 0, is 0 Testing arrays... COUNT_NORMAL: should be 2, is 2 COUNT_RECURSIVE: should be 8, is 8 -- PHP CVS 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 CVS Mailing List (http://www.php.net/) To
Re: [PHP-DEV] Re: CVS Account Request: iliaa
Well, I don't see it in the DB. Please fill out the form again. -Rasmus On Wed, 9 Jan 2002, Ilia A. wrote: I've sent one on Jan. 2, 2002 it appeared on the php-dev list. Here is the copy of the message, just in case. [PHP-DEV] CVS Account Request: iliaa Date: Wed, 2 Jan 2002 19:15:46 -0500 From: Ilia A. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Reply to: [EMAIL PROTECTED] Maintain the SHMOP module. -- 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: iliaa
Maintain the SHMOP modules its documentation. -- 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 #14955 Updated: PHP crashes with bogus session.save_path
ID: 14955 Updated by: yohgaki Old Summary: php chrashes if i use some session functions Reported By: [EMAIL PROTECTED] Old Status: Open Status: Duplicate Bug Type: Reproducible crash Operating System: WinXP PHP Version: 4.1.1 Old Assigned To: Assigned To: yohgaki New Comment: Dup of other bug report, I don't have time to find #. Changed title. Assinged to me, so that I don't forget about it. To reporter: set correct save_path, then it should work :) Previous Comments: [2002-01-09 18:27:07] [EMAIL PROTECTED] OS: WinXP PHP: 4.1.1 Apache: neweste stable windows version I tryed 5 things now: ### first ### $id = 143445254; session_id($id); session_start(); ### second ### session_register(count); $count++; ### third ### $s_permission = false; @session_start(); session_register(s_permission); $fallback = session_name().=.session_id(); ### fourth ### session_start(); ### fifth ### session_register(); All everytime PHP.exe crashes (AppName: php.exeAppVer: 0.0.0.0 ModName: php4ts.dll ModVer: 0.0.0.0 Offset: 000a956c) What the hell is the problem? ### php.ini ### [Session] ; Handler used to store/retrieve data. session.save_handler = files ; Argument passed to save_handler. In the case of files, this is the path ; where data files are stored. Note: Windows users have to change this ; variable in order to use PHP's session functions. session.save_path = /tmp ; Whether to use cookies. session.use_cookies = 1 ; Name of the session (used as cookie name). session.name = PHPSESSID ; Initialize session on request startup. session.auto_start = 0 ; Lifetime in seconds of cookie or, if 0, until browser is restarted. session.cookie_lifetime = 0 ; The path for which the cookie is valid. session.cookie_path = / ; The domain for which the cookie is valid. session.cookie_domain = ; Handler used to serialize data. php is the standard serializer of PHP. session.serialize_handler = php ; Percentual probability that the 'garbage collection' process is started ; on every session initialization. session.gc_probability = 1 ; After this number of seconds, stored data will be seen as 'garbage' and ; cleaned up by the garbage collection process. session.gc_maxlifetime = 1440 ; Check HTTP Referer to invalidate externally stored URLs containing ids. session.referer_check = ; How many bytes to read from the file. session.entropy_length = 0 ; Specified here to create the session id. session.entropy_file = ;session.entropy_length = 16 ;session.entropy_file = /dev/urandom ; Set to {nocache,private,public} to determine HTTP caching aspects. session.cache_limiter = nocache ; Document expires after n minutes. session.cache_expire = 180 ; use transient sid support if enabled by compiling with --enable-trans-sid. session.use_trans_sid = 1 url_rewriter.tags = a=href,area=href,frame=src,input=src,form=fakeentry ### apache config, php stuff ### # And for PHP 4.x, use: # ScriptAlias /php/ C:/server/httpd/php/ AddType application/x-httpd-php .php AddType application/x-httpd-php .php3 AddType application/x-httpd-php .php4 AddType application/x-httpd-php .phtml Action application/x-httpd-php /php/php.exe AddType application/x-tar .tgz ### apache error log ### [Thu Jan 10 00:26:04 2002] [error] [client 127.0.0.1] Premature end of script headers: c:/server/httpd/php/php.exe Anyone can help me plz??? Edit this bug report at http://bugs.php.net/?id=14955edit=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] Bug #14953 Updated: --without-pear disappeared ?!
ID: 14953 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: PHP options/info functions Operating System: OpenBSD 3.0 PHP Version: 4.1.1 New Comment: Works for me with 4.2.0-dev. Closed. Previous Comments: [2002-01-09 12:43:20] [EMAIL PROTECTED] ./configure --help | more ... --without-pear disable pear ... but if I make ./configure --without-pear ... --without-pear option not valid why ? Also mysql. --with-mysql=/usr/local/lib/mysql PHP still prints out warning, if will use MySQL with other software you should use mysql libs... Bye. Edit this bug report at http://bugs.php.net/?id=14953edit=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] Bug #13345 Updated: PHP hangs
ID: 13345 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: IIS related Operating System: Windows Advanced Server PHP Version: 4.0.6 New Comment: Apparently, when my php produces to many warnings, Apache chokes on it. I rewrote my script to produce less warnings and now it does not hang anymore. I am using php.ini-recommended from the 4.1.1 ZIP distrib. Running from the command line, the warnings seem to go to stderr, which does not make sense with CGI? Previous Comments: [2002-01-09 18:30:18] [EMAIL PROTECTED] Same here with 4.1.1 and Apache 1.3.22 on Windows 2000. If I stop the transfer the php.exe process still runs as an Apache child and you cannot kill it. Running the same script on the command line works always. Note that my script uses odbc. [2001-09-17 09:53:40] [EMAIL PROTECTED] I have installed sucessfully PHP 4.0.6 on my Windows Advanced Server with IIS 5.0. And I have tested the phpinfo() several times however everynow and then when I try to access the page or any other php page on the server, it hangs and the browser keeps on saying trying to connect. I've tried to reboot the webserver ( :( ) several times and it works first then it hangs again. I really need to know what is going on here since I wanna host some php sites for clients and it is not a good idea at all to reboot a webserver every day. Thank you, Wissam Edit this bug report at http://bugs.php.net/?id=13345edit=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] Bug #13486 Updated: Apache/PHP hangs
ID: 13486 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Closed Bug Type: Scripting Engine problem Operating System: SunOS 5.8 PHP Version: 4.0.6 New Comment: Apparently, when my php produces to many warnings, Apache chokes on it. I rewrote my script to produce less warnings and now it does not hang anymore. I am using php.ini-recommended from the 4.1.1 ZIP distrib. Running from the command line, the warnings seem to go to stderr, which does not make sense with CGI? Previous Comments: [2002-01-09 18:26:11] [EMAIL PROTECTED] Same here with 4.1.1 and Apache 1.3.22 on Windows 2000. [2002-01-05 16:48:23] [EMAIL PROTECTED] No feedback. Closing. [2001-12-14 13:50:48] [EMAIL PROTECTED] Could you try 4.1.0 and reoprt the result? [2001-09-28 14:55:21] [EMAIL PROTECTED] Hello, I got a weird problem here -- Apache (1.3.20) + PHP 4.06 hangs. No core dump, no log entries -- just hangs. Request to ANY php file produces no results (not even headers returned), however request to .html files work just fine -- which leads me to beleave that this might be PHP related issue. Apache restart fixes the problem. This issue happened couple times... Today I was able to reproduce it by running ./ab -n 1 -c 10 http:.../index.php The third time i ran this, PHP stopped responding. Because there are no core dumps, nor log file entries, the only thing I could do was to runn truss on apache process. PHP was compiled with the following options: ./configure --disable-debug --with-mysql=/usr/local/mysql --enable-track-vars --disable-display-source --enable-memory-limit --with-apxs=/usr/local/etc/apache/bin/apxs index.php is a very simple script: ?php require(header.inc); ? BPlease enter your query:/B form name=searchform action=http://search.symbol.com/search.php; method=get onSubmit=this.search.value=this.search.value.toLowerCase();return true input type=text name=search value= input type=submit value=Search /form Below is output of truss on both /test.html and /index.php (same pid)... It seems that /index.php request gets Err#25 ENOTTY Any idea why this is happening? Any suggestions on how to fix this are very much appreciated. Please let me know if there is any more info I can provide. Is it a know issue with Sun? I could not find similar posts on bugs.php.net... --- TRUSS for /index.php fcntl(18, F_SETLKW, 0x000E5410) (sleeping...) fcntl(18, F_SETLKW, 0x000E5410) = 0 accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) (sleeping...) accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) = 3 fcntl(18, F_SETLKW, 0x000E5434) = 0 sigaction(SIGUSR1, 0xFFBEF670, 0xFFBEF6F0) = 0 getsockname(3, 0xFFBEF7C8, 0xFFBEF7DC, 1) = 0 setsockopt(3, 6, 1, 0xFFBEF72C, 4, 1) = 0 read(3, G E T / i n d e x . p.., 4096) = 92 sigaction(SIGUSR1, 0xFFBED568, 0xFFBED5E8) = 0 time() = 1001694729 stat(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, 0x0012E958) = 0 umask(077) = 022 umask(022) = 077 setitimer(ITIMER_PROF, 0xFFBEF390, 0x) = 0 sigaction(SIGPROF, 0xFFBEF260, 0xFFBEF2E0) = 0 sigprocmask(SIG_UNBLOCK, 0xFFBEF380, 0x) = 0 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBEE278)= 0 stat64(/, 0xFFBEE1E0) = 0 open64(./../, O_RDONLY|O_NDELAY) = 5 fcntl(5, F_SETFD, 0x0001) = 0 fstat64(5, 0xFFBECC00) = 0 fstat64(5, 0xFFBEE278) = 0 close(5)= 0 chdir(/usr/local/etc/apache/htdocs/search.symbol.com) = 0 open(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, O_RDONLY) = 5 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBED5B0)= 0 stat64(/, 0xFFBED518) = 0 open64(./../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 128 close(6)= 0 open64(./../../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 384 close(6)
[PHP-DEV] Bug #14957: --with-dom-xslt dosn't compile (patch included ...)
From: [EMAIL PROTECTED] Operating system: linux PHP version: 4.0CVS-2002-01-09 PHP Bug Type: DOM XML related Bug description: --with-dom-xslt dosn't compile (patch included ...) one header line is missing. here's the patch: RCS file: /repository/php4/ext/domxml/php_domxml.h,v retrieving revision 1.33 diff -u -r1.33 php_domxml.h --- php_domxml.h9 Jan 2002 03:42:30 - 1.33 +++ php_domxml.h10 Jan 2002 00:43:23 - @@ -36,6 +36,7 @@ #include libxml/xpointer.h #endif #if HAVE_DOMXSLT +#include libxslt/xsltconfig.h #include libxslt/xsltInternals.h #include libxslt/xsltutils.h #include libxslt/transform.h -- Edit bug report at: http://bugs.php.net/?id=14957edit=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: SOAP and OpenGL stuff
--- Rasmus Lerdorf [EMAIL PROTECTED] wrote: Brad, I have created your CVS account, but please have a look at the existing ext/xmlrpc extension and see what sort of overlap there is with your php_soap extension. ext/xmlrpc has SOAP 1.1 support. I didn't realize xmlrpc supported soap... But.. the soap extension that im working on will be much eaiser and readable to use than xmlrpc.. And the opengl extension might be a good candidate for PECL (The C extension repository that is part of PEAR). When I first mailed you guys about this that what you said... but you also said that it wasn't fully completed.. so i was told to hold on.. and never i never was reached again. is their any doc's on the PECL? -Rasmus __ Do You Yahoo!? Send FREE video emails in Yahoo! Mail! http://promo.yahoo.com/videomail/ -- 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 #13486 Updated: Apache/PHP hangs
ID: 13486 Updated by: yohgaki Reported By: [EMAIL PROTECTED] Status: Closed Bug Type: Scripting Engine problem Operating System: SunOS 5.8 PHP Version: 4.0.6 New Comment: CGI seems prints error to stderr for a long time. It would not be changed. Anyway, if you could reproduce this problem, feel free to reopen this bug report and add more detailed description. Previous Comments: [2002-01-09 19:40:59] [EMAIL PROTECTED] Apparently, when my php produces to many warnings, Apache chokes on it. I rewrote my script to produce less warnings and now it does not hang anymore. I am using php.ini-recommended from the 4.1.1 ZIP distrib. Running from the command line, the warnings seem to go to stderr, which does not make sense with CGI? [2002-01-09 18:26:11] [EMAIL PROTECTED] Same here with 4.1.1 and Apache 1.3.22 on Windows 2000. [2002-01-05 16:48:23] [EMAIL PROTECTED] No feedback. Closing. [2001-12-14 13:50:48] [EMAIL PROTECTED] Could you try 4.1.0 and reoprt the result? [2001-09-28 14:55:21] [EMAIL PROTECTED] Hello, I got a weird problem here -- Apache (1.3.20) + PHP 4.06 hangs. No core dump, no log entries -- just hangs. Request to ANY php file produces no results (not even headers returned), however request to .html files work just fine -- which leads me to beleave that this might be PHP related issue. Apache restart fixes the problem. This issue happened couple times... Today I was able to reproduce it by running ./ab -n 1 -c 10 http:.../index.php The third time i ran this, PHP stopped responding. Because there are no core dumps, nor log file entries, the only thing I could do was to runn truss on apache process. PHP was compiled with the following options: ./configure --disable-debug --with-mysql=/usr/local/mysql --enable-track-vars --disable-display-source --enable-memory-limit --with-apxs=/usr/local/etc/apache/bin/apxs index.php is a very simple script: ?php require(header.inc); ? BPlease enter your query:/B form name=searchform action=http://search.symbol.com/search.php; method=get onSubmit=this.search.value=this.search.value.toLowerCase();return true input type=text name=search value= input type=submit value=Search /form Below is output of truss on both /test.html and /index.php (same pid)... It seems that /index.php request gets Err#25 ENOTTY Any idea why this is happening? Any suggestions on how to fix this are very much appreciated. Please let me know if there is any more info I can provide. Is it a know issue with Sun? I could not find similar posts on bugs.php.net... --- TRUSS for /index.php fcntl(18, F_SETLKW, 0x000E5410) (sleeping...) fcntl(18, F_SETLKW, 0x000E5410) = 0 accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) (sleeping...) accept(16, 0xFFBEF7B8, 0xFFBEF7DC, 1) = 3 fcntl(18, F_SETLKW, 0x000E5434) = 0 sigaction(SIGUSR1, 0xFFBEF670, 0xFFBEF6F0) = 0 getsockname(3, 0xFFBEF7C8, 0xFFBEF7DC, 1) = 0 setsockopt(3, 6, 1, 0xFFBEF72C, 4, 1) = 0 read(3, G E T / i n d e x . p.., 4096) = 92 sigaction(SIGUSR1, 0xFFBED568, 0xFFBED5E8) = 0 time() = 1001694729 stat(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, 0x0012E958) = 0 umask(077) = 022 umask(022) = 077 setitimer(ITIMER_PROF, 0xFFBEF390, 0x) = 0 sigaction(SIGPROF, 0xFFBEF260, 0xFFBEF2E0) = 0 sigprocmask(SIG_UNBLOCK, 0xFFBEF380, 0x) = 0 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBEE278)= 0 stat64(/, 0xFFBEE1E0) = 0 open64(./../, O_RDONLY|O_NDELAY) = 5 fcntl(5, F_SETFD, 0x0001) = 0 fstat64(5, 0xFFBECC00) = 0 fstat64(5, 0xFFBEE278) = 0 close(5)= 0 chdir(/usr/local/etc/apache/htdocs/search.symbol.com) = 0 open(/usr/local/etc/apache/htdocs/search.symbol.com/index.php, O_RDONLY) = 5 pathconf(., _PC_PATH_MAX) = 1024 stat64(./, 0xFFBED5B0)= 0 stat64(/, 0xFFBED518) = 0 open64(./../, O_RDONLY|O_NDELAY) = 6 fcntl(6, F_SETFD, 0x0001) = 0 fstat64(6, 0xFFBECB38) = 0 fstat64(6, 0xFFBED5B0) = 0 getdents64(6, 0x0011AA90, 1048) = 128 close(6)= 0 open64(./../../,
[PHP-DEV] Bug #14958: flex error in compiling Zend enginge
From: [EMAIL PROTECTED] Operating system: linux debian unstable PHP version: 4.0CVS-2002-01-09 PHP Bug Type: Compile Failure Bug description: flex error in compiling Zend enginge it seems, that since my debian unstable upgraded from flex 2.5.4a-14 to 2.5.4a-15, I can't compile the Zend Engine anymore. It throws an error in zend_ini_parser.c and if I compare a zend_ini_parser.c genearated with the -14 version and one from -15 version, there are indeed differences where the error occurs. here's the error-mesage from make: /bin/sh ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../main -DLINUX=22 -DUSE_HSREGEX -I../TSRM -g -Wall -prefer-pic -c zend_ini_scanner.c gcc -DHAVE_CONFIG_H -I. -I. -I../main -DLINUX=22 -DUSE_HSREGEX -I../TSRM -g -Wall -c zend_ini_scanner.c -fPIC -DPIC -o zend_ini_scanner.lo zend_ini_scanner.c: In function `ini_lex': zend_ini_scanner.c:826: warning: label `find_rule' defined but not used zend_ini_scanner.c: In function `yy_get_next_buffer': zend_ini_scanner.c:1243: `errno' undeclared (first use in this function) zend_ini_scanner.c:1243: (Each undeclared identifier is reported only once zend_ini_scanner.c:1243: for each function it appears in.) zend_ini_scanner.c:1243: `EINTR' undeclared (first use in this function) ./zend_ini_scanner.l: At top level: zend_ini_scanner.c:1900: warning: `yy_flex_realloc' defined but not used zend_ini_scanner.c:1350: warning: `yyunput' defined but not used make[1]: *** [zend_ini_scanner.lo] Error 1 make[1]: Leaving directory `/opt/cvs/php4/Zend' make: *** [all-recursive] Error 1 and here the diff between the both zend_ini_scanner.c versions: --- Z/zend_ini_scanner.cThu Jan 10 01:28:37 2002 +++ Zend/zend_ini_scanner.c Thu Jan 10 01:52:57 2002 @@ -698,9 +698,17 @@ YY_FATAL_ERROR( input in flex scanner failed ); \ result = n; \ } \ - else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \ - ferror( yyin ) ) \ - YY_FATAL_ERROR( input in flex scanner failed ); + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( input in flex scanner failed ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } #endif and here the relevant part from the debian-changelog: flex (2.5.4a-15) unstable; urgency=low * if a signal is delivered while the parser is in the read routine (coded by flex), the result is flex reports and YY_FATAL_ERROR causing plan to exit. The race condition appears much more frequently than one might expect because plan spends a good deal of time in read routine while gcc is preparing the input. I cleaned up another problem case beyond what is given in the patch. closes: Bug#125611 I have no idea about this flex stuff, so maybe someone else out there can fix that :) -- Edit bug report at: http://bugs.php.net/?id=14958edit=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: SOAP and OpenGL stuff
Brad Lafountain wrote: --- Rasmus Lerdorf [EMAIL PROTECTED] wrote: And the opengl extension might be a good candidate for PECL (The C extension repository that is part of PEAR). When I first mailed you guys about this that what you said... but you also said that it wasn't fully completed.. so i was told to hold on.. and never i never was reached again. is their any doc's on the PECL? Not much AFAIK, http://pear.php.net/faq.php New extensions supposed to be located under pear/PECL/, I think. There is no download URL, but it seems people are working on it. -- Yasuo Ohgaki -- 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 #14957 Updated: --with-dom-xslt dosn't compile (patch included ...)
ID: 14957 Updated by: mfischer Old Summary: --with-dom-xslt dosn't compile (patch included ...) Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: DOM XML related Operating System: linux PHP Version: 4.0CVS-2002-01-09 New Comment: Fixed in CVS (why don't we've more guys like you? :) Previous Comments: [2002-01-09 19:44:02] [EMAIL PROTECTED] one header line is missing. here's the patch: RCS file: /repository/php4/ext/domxml/php_domxml.h,v retrieving revision 1.33 diff -u -r1.33 php_domxml.h --- php_domxml.h9 Jan 2002 03:42:30 - 1.33 +++ php_domxml.h10 Jan 2002 00:43:23 - @@ -36,6 +36,7 @@ #include libxml/xpointer.h #endif #if HAVE_DOMXSLT +#include libxslt/xsltconfig.h #include libxslt/xsltInternals.h #include libxslt/xsltutils.h #include libxslt/transform.h Edit this bug report at http://bugs.php.net/?id=14957edit=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] Bug #14958 Updated: flex error in compiling Zend enginge
ID: 14958 Updated by: mfischer Reported By: [EMAIL PROTECTED] Old Status: Open Status: Feedback Bug Type: Compile Failure Operating System: linux debian unstable PHP Version: 4.0CVS-2002-01-09 New Comment: From the error message I'ld say you just need to include errno.h in zend_ini_scanner.l (like in zend_language_scanner.l), can you verify this? Previous Comments: [2002-01-09 19:57:14] [EMAIL PROTECTED] it seems, that since my debian unstable upgraded from flex 2.5.4a-14 to 2.5.4a-15, I can't compile the Zend Engine anymore. It throws an error in zend_ini_parser.c and if I compare a zend_ini_parser.c genearated with the -14 version and one from -15 version, there are indeed differences where the error occurs. here's the error-mesage from make: /bin/sh ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../main -DLINUX=22 -DUSE_HSREGEX -I../TSRM -g -Wall -prefer-pic -c zend_ini_scanner.c gcc -DHAVE_CONFIG_H -I. -I. -I../main -DLINUX=22 -DUSE_HSREGEX -I../TSRM -g -Wall -c zend_ini_scanner.c -fPIC -DPIC -o zend_ini_scanner.lo zend_ini_scanner.c: In function `ini_lex': zend_ini_scanner.c:826: warning: label `find_rule' defined but not used zend_ini_scanner.c: In function `yy_get_next_buffer': zend_ini_scanner.c:1243: `errno' undeclared (first use in this function) zend_ini_scanner.c:1243: (Each undeclared identifier is reported only once zend_ini_scanner.c:1243: for each function it appears in.) zend_ini_scanner.c:1243: `EINTR' undeclared (first use in this function) ./zend_ini_scanner.l: At top level: zend_ini_scanner.c:1900: warning: `yy_flex_realloc' defined but not used zend_ini_scanner.c:1350: warning: `yyunput' defined but not used make[1]: *** [zend_ini_scanner.lo] Error 1 make[1]: Leaving directory `/opt/cvs/php4/Zend' make: *** [all-recursive] Error 1 and here the diff between the both zend_ini_scanner.c versions: --- Z/zend_ini_scanner.cThu Jan 10 01:28:37 2002 +++ Zend/zend_ini_scanner.c Thu Jan 10 01:52:57 2002 @@ -698,9 +698,17 @@ YY_FATAL_ERROR( input in flex scanner failed ); \ result = n; \ } \ - else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \ - ferror( yyin ) ) \ - YY_FATAL_ERROR( input in flex scanner failed ); + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( input in flex scanner failed ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } #endif and here the relevant part from the debian-changelog: flex (2.5.4a-15) unstable; urgency=low * if a signal is delivered while the parser is in the read routine (coded by flex), the result is flex reports and YY_FATAL_ERROR causing plan to exit. The race condition appears much more frequently than one might expect because plan spends a good deal of time in read routine while gcc is preparing the input. I cleaned up another problem case beyond what is given in the patch. closes: Bug#125611 I have no idea about this flex stuff, so maybe someone else out there can fix that :) Edit this bug report at http://bugs.php.net/?id=14958edit=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] Bug #14935 Updated: spaces NOT escaped by A..z
ID: 14935 Updated by: irc-html Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Documentation problem PHP Version: 4.1.1 New Comment: Confirmed, will fix in CVS. Status - Closed Previous Comments: [2002-01-08 15:24:48] [EMAIL PROTECTED] http://www.php.net/manual/en/function.addcslashes.php says `and space characters' but this is not true; on my system addcslashes('foo[ ]','A..z') results in \f\o\o\[ \] not \f\o\o\[\ \] Edit this bug report at http://bugs.php.net/?id=14935edit=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] Bug #14873 Updated: docu of ob_gzhandler not uptodate
ID: 14873 Updated by: irc-html Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Documentation problem Operating System: all PHP Version: 4.1.0 Old Assigned To: Assigned To: irc-html New Comment: Will update the documentation, thanks for the report. Assigning to myself so I'll remember. :) Previous Comments: [2002-01-05 10:08:14] [EMAIL PROTECTED] Documentation sais, that ob_gzhandler() needs 1 parameter, but in reality it needs 2. I assume, that this second param was added in 4.1.0. Edit this bug report at http://bugs.php.net/?id=14873edit=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] Bug #14873 Updated: docu of ob_gzhandler not uptodate
ID: 14873 Updated by: irc-html Reported By: [EMAIL PROTECTED] Old Status: Open Status: Assigned Bug Type: Documentation problem Operating System: all PHP Version: 4.1.0 Assigned To: irc-html Previous Comments: [2002-01-05 10:08:14] [EMAIL PROTECTED] Documentation sais, that ob_gzhandler() needs 1 parameter, but in reality it needs 2. I assume, that this second param was added in 4.1.0. Edit this bug report at http://bugs.php.net/?id=14873edit=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] Bug #14797 Updated: include (_path) in Apache SAPI and CGI on Win98SE does not work
ID: 14797 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Scripting Engine problem Operating System: Windows 98 SE PHP Version: 4.1.0 New Comment: Martin, Did my suggestion work for you? Where you missing the drive letter? -Garth Previous Comments: [2002-01-07 14:07:01] [EMAIL PROTECTED] From: Garth Dahlstrom [EMAIL PROTECTED] Subject: Re: PHP Bug #14797 == #14563 Date: Mon, 07 Jan 2002 2:36:45 EDT I did some work trying to figure this out using FoxServ off of sf.net... I can recreate the bug when I don't prefix my DocumentRoot with the drive letter... DocumentRoot C:\apache/htdocs # no error DocumentRoot /apache/htdocs# error I find it odd that they both work on my machine provided I don't provide an include_path and the syntax of the include_path can lack the drive letter and work just fine. (i.e. include_path=.;/apache/includes is ok as long as the Docroot in httpd.conf has a C:\ in it) Wondering if you can verify this result... It may be just a matter of PHP not using C:\ as a default drive after 4.04 or something... -Garth Northern.CA ===-- http://www.northern.ca Canada's Search Engine [2002-01-06 06:30:33] [EMAIL PROTECTED] From: Garth Dahlstrom [EMAIL PROTECTED] Subject: PHP Bug #14797 == #14563 Date: Sat, 05 Jan 2002 13:15:45 EDT Martin, Indeed you have the same bug I have, I don't have a Win98 system so I could not comment on whether or not it was for all of Win32 when I opened 14563. I downgraded my set-up to a copy of PHP 4.04, and found your statement regarding versions before 4.05RC1 to be true also... setting my include_path = .;/apache/includes fails with the same error, however setting include_path to ;.;/apache/includes works properly. Wondering if this workaround would work after 4.04 on Win2K, I upgraded my PHP version back up maintaining the same PHP.ini from 4.04... The workaround doesn't work on 4.06, 4.08, 4.1.0, or 4.1.1. They have closed my bugs as being bogus and I can't post into your bug to describe these findings, so if you could post this message into Bug #14797, maybe it would be helpful in keeping you bug alive. I am thinking of building a mini-distribution of Apache+PHP (4.04 + 4.06 + 4.1.1) to see if I can help more folks reproduce it. Regards, -GED Northern.CA ===-- http://www.northern.ca Canada's Search Engine [2002-01-02 08:58:27] [EMAIL PROTECTED] With PHP Version 4.0.5RC1 an inlude-path set to ;.;./; it works with SAPI, but with 4.0.6 and newer it's the same like 4.1.0 Martin [2002-01-02 08:30:47] [EMAIL PROTECTED] Hello, I can't run PHP Version 4.1.0 under Windows 95/98 4.10, there are massive problems when I try to include a file: Server API CGI -- - It's possible to set the include-path in php.ini. - Scripts without any include statement work well. - include statements with a relative path work. - include statements with an absolute path do not work, there is the following error: Failed opening '/foo/test.php' for inclusion Server API Apache - - It is not possible to set the include-path in php.ini to an other value than . If I do, there will be everytime the same error: Failed opening 'foo/index.php' for inclusion (include_path='.;/foo') in Unknown on line 0 - If I set the include-path in php.ini to and in a script with ini_set(include_path, $new_inc_path) to the desired path, then php shows the same behaviour like Server API CGI - only relative paths work. I think this could be the bug #11612 or #14563, bit I don't use Win2k, I'm using Win 98 SE. Martin Edit this bug report at http://bugs.php.net/?id=14797edit=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] Bug #14525 Updated: Access Violation at 0528B2F6 using php4isapi.dll on Deerfield WebSite 3.1.11
ID: 14525 Comment by: [EMAIL PROTECTED] Old Reported By: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: IIS related Operating System: Windows NT 4.0 SP6a PHP Version: 4.1.0 New Comment: Same problem with 4.1.1 Previous Comments: [2001-12-14 15:13:06] [EMAIL PROTECTED] When running PHP 4.1.0 (zip package) on Deerfield.com's WebSite 3.1.11 server (formerly known as O'Reilly WebSite Professional) using php4isapi.dll, every single request for a PHP file results in the following error message (which is the only thing that gets sent to the browser): PHP has encountered an Access Violation at 0528B2F6 This did not happen in PHP 4.0.6. Edit this bug report at http://bugs.php.net/?id=14525edit=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] Bug #12093 Updated: persistent db conns
ID: 12093 Updated by: irc-html Reported By: [EMAIL PROTECTED] Old Status: Open Status: Closed Bug Type: Documentation problem Operating System: n/a PHP Version: 4.0.6 New Comment: All pconnect functions have links to the 'Persistent Database Connections' chapter. Most (if not all) also state that persistent connections only work with module version of PHP. Status - Closed Previous Comments: [2001-10-30 22:53:00] [EMAIL PROTECTED] missing status [2001-07-12 19:41:48] [EMAIL PROTECTED] IMHO a reference to this should be made from the relevant functions. [2001-07-12 06:41:49] [EMAIL PROTECTED] From Chapter 22: Persistent connections: (4th alinea on http://www.php.net/manual/en/features.persistent-connections.php): The first method is to use PHP as a CGI wrapper. When run this way, an instance of the PHP interpreter is created and destroyed for every page request (for a PHP page) to your web server. Because it is destroyed after every request, any resources that it acquires (such as a link to an SQL database server) are closed when it is destroyed. In this case, you do not gain anything from trying to use persistent connections -- they simply don't persist. [2001-07-12 06:20:07] [EMAIL PROTECTED] The documentation does not reflect the fact that running PHP through a CGI interface will force persistent db connections to close on script end. Example, mssql_pconnect Edit this bug report at http://bugs.php.net/?id=12093edit=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]