#50632 [NEW]: Return default value if var is undefined

2010-01-02 Thread gmblar+php at gmail dot com
From: gmblar+php at gmail dot com
Operating system: all
PHP version:  5.3.1
PHP Bug Type: Filter related
Bug description:  Return default value if var is undefined

Description:

if $_GET['foo'] is undefined, filter functions return NULL instead of 
the default value defined in options.

Reproduce code:
---
 FILTER_REQUIRE_SCALAR,
'options' => array(
'default' => 23,
'min_range' => 5,
'max_range' => 42
)
));

var_dump($foo);

?>

Expected result:

int(23)

Actual result:
--
NULL

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



#50633 [NEW]: Add constant FILTER_EXCEPTION_ON_FAILURE to throw exceptions

2010-01-02 Thread gmblar+php at gmail dot com
From: gmblar+php at gmail dot com
Operating system: all
PHP version:  5.3.1
PHP Bug Type: Filter related
Bug description:  Add constant FILTER_EXCEPTION_ON_FAILURE to throw exceptions

Description:

Add constant FILTER_EXCEPTION_ON_FAILURE to throw meaningful exceptions 
why filter fails

Reproduce code:
---
 FILTER_REQUIRE_SCALAR + FILTER_EXCEPTION_ON_FAILURE,
'options' => array(
'min_range' => 5,
'max_range' => 42
)
));

var_dump($foo);

?>

Expected result:

Fatal error: Uncaught exception 'OutOfBoundsException' with message 'foo 
must an integer in range between 5 and 42' in input.php:3 Stack trace: 
#0 {main} thrown in input.php on line 3

Actual result:
--
bool(false)

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



#49267 [Com]: Linking fails for iconv: "Undefined symbols: _libiconv"

2010-01-02 Thread iongion at yahoo dot com
 ID:   49267
 Comment by:   iongion at yahoo dot com
 Reported By:  s dot rost at ewerk dot com
 Status:   No Feedback
 Bug Type: Compile Failure
 Operating System: Mac OSX 10.6 Snow Leopard
 PHP Version:  5.3, 6 (2009-08-18)
 Assigned To:  scottmac
 New Comment:

It does not work for me, same Snow Leopard

I've added all possible combination of fixes

Using the latest php snapshot php5.3-201001012330


http://www.opensource.apple.com/source/apache_mod_php/apache_mod_php-
53/patches/iconv.patch


Here is the build script

./configure \
'--with-iconv-dir=/usr' \
'--prefix=/usr' \
'--mandir=/usr/share/man' \
'--infodir=/usr/share/info' \
'--sysconfdir=/private/etc' \
'--with-apxs2=/usr/sbin/apxs' \
'--enable-cli' \
'--with-config-file-path=/etc' \
'--with-libxml-dir=/usr' \
'--with-openssl=/usr' \
'--with-kerberos=/usr' \
'--with-zlib=/usr' \
'--enable-bcmath' \
'--with-bz2=/usr' \
'--enable-calendar' \
'--with-curl=/usr' \
'--enable-exif' \
'--enable-ftp' \
'--with-gd' \
'--with-jpeg-dir=/usr/local' \
'--with-png-dir=/usr/local' \
'--enable-gd-native-ttf' \
'--with-ldap=/usr' \
'--with-ldap-sasl=/usr' \
'--enable-mbstring' \
'--enable-mbregex' \
'--with-mysql=mysqlnd' \
'--with-mysqli=mysqlnd' \
'--with-pdo-mysql=mysqlnd' \
'--with-iodbc=/usr' \
'--enable-shmop' \
'--with-snmp=/usr' \
'--enable-soap' \
'--enable-sockets' \
'--enable-sysvmsg' \
'--enable-sysvsem' \
'--enable-sysvshm' \
'--with-xmlrpc' \
'--with-xsl=/usr' \
'--with-pcre-regex' \
'--with-mcrypt' \
'--with-mhash' \
'--enable-zip' \
'--with-curl' \
'--with-pear'

With iconv dir set to /usr/local, still not working, arghhh


Previous Comments:


[2010-01-02 00:57:29] conrad dot tim at gmail dot com

Solved for me by applying the patch provided by Apple mentioned in bug

#48195.

http://www.opensource.apple.com/source/apache_mod_php/apache_mod_php-
53/patches/iconv.patch



[2010-01-02 00:37:35] conrad dot tim at gmail dot com

This bug remains for me. On Snow Leapoard (10.6.2 Build 10C540) using 
php5.3-201001012330 snapshot).

Output ending the make process:
Undefined symbols:
  "_libiconv", referenced from:
  __php_iconv_strlen in iconv.o
  _php_iconv_string in iconv.o
  _php_iconv_string in iconv.o
  __php_iconv_strpos in iconv.o
  __php_iconv_appendl in iconv.o
  __php_iconv_appendl in iconv.o
  _zif_iconv_substr in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [libs/libphp5.bundle] Error 1



[2010-01-02 00:37:24] conrad dot tim at gmail dot com

This bug remains for me. On Snow Leapoard (10.6.2 Build 10C540) using 
php5.3-201001012330 snapshot).

Output ending the make process:
Undefined symbols:
  "_libiconv", referenced from:
  __php_iconv_strlen in iconv.o
  _php_iconv_string in iconv.o
  _php_iconv_string in iconv.o
  __php_iconv_strpos in iconv.o
  __php_iconv_appendl in iconv.o
  __php_iconv_appendl in iconv.o
  _zif_iconv_substr in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [libs/libphp5.bundle] Error 1



[2009-12-30 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2009-12-22 10:00:04] j...@php.net

Please try using this snapshot:

  http://snaps.php.net/php5.3-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

And please, don't report multiple issues in one report. That missing
-lresolv issue should be fixed, right? (if not, report it separately!)



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/49267

--

#49267 [Com]: Linking fails for iconv: "Undefined symbols: _libiconv"

2010-01-02 Thread iongion at yahoo dot com
 ID:   49267
 Comment by:   iongion at yahoo dot com
 Reported By:  s dot rost at ewerk dot com
 Status:   No Feedback
 Bug Type: Compile Failure
 Operating System: Mac OSX 10.6 Snow Leopard
 PHP Version:  5.3, 6 (2009-08-18)
 Assigned To:  scottmac
 New Comment:

This is the output of make at its last step before throwing the hell

http://dpaste.com/hold/140147/


Previous Comments:


[2010-01-02 13:36:06] iongion at yahoo dot com

It does not work for me, same Snow Leopard

I've added all possible combination of fixes

Using the latest php snapshot php5.3-201001012330


http://www.opensource.apple.com/source/apache_mod_php/apache_mod_php-
53/patches/iconv.patch


Here is the build script

./configure \
'--with-iconv-dir=/usr' \
'--prefix=/usr' \
'--mandir=/usr/share/man' \
'--infodir=/usr/share/info' \
'--sysconfdir=/private/etc' \
'--with-apxs2=/usr/sbin/apxs' \
'--enable-cli' \
'--with-config-file-path=/etc' \
'--with-libxml-dir=/usr' \
'--with-openssl=/usr' \
'--with-kerberos=/usr' \
'--with-zlib=/usr' \
'--enable-bcmath' \
'--with-bz2=/usr' \
'--enable-calendar' \
'--with-curl=/usr' \
'--enable-exif' \
'--enable-ftp' \
'--with-gd' \
'--with-jpeg-dir=/usr/local' \
'--with-png-dir=/usr/local' \
'--enable-gd-native-ttf' \
'--with-ldap=/usr' \
'--with-ldap-sasl=/usr' \
'--enable-mbstring' \
'--enable-mbregex' \
'--with-mysql=mysqlnd' \
'--with-mysqli=mysqlnd' \
'--with-pdo-mysql=mysqlnd' \
'--with-iodbc=/usr' \
'--enable-shmop' \
'--with-snmp=/usr' \
'--enable-soap' \
'--enable-sockets' \
'--enable-sysvmsg' \
'--enable-sysvsem' \
'--enable-sysvshm' \
'--with-xmlrpc' \
'--with-xsl=/usr' \
'--with-pcre-regex' \
'--with-mcrypt' \
'--with-mhash' \
'--enable-zip' \
'--with-curl' \
'--with-pear'

With iconv dir set to /usr/local, still not working, arghhh



[2010-01-02 00:57:29] conrad dot tim at gmail dot com

Solved for me by applying the patch provided by Apple mentioned in bug

#48195.

http://www.opensource.apple.com/source/apache_mod_php/apache_mod_php-
53/patches/iconv.patch



[2010-01-02 00:37:35] conrad dot tim at gmail dot com

This bug remains for me. On Snow Leapoard (10.6.2 Build 10C540) using 
php5.3-201001012330 snapshot).

Output ending the make process:
Undefined symbols:
  "_libiconv", referenced from:
  __php_iconv_strlen in iconv.o
  _php_iconv_string in iconv.o
  _php_iconv_string in iconv.o
  __php_iconv_strpos in iconv.o
  __php_iconv_appendl in iconv.o
  __php_iconv_appendl in iconv.o
  _zif_iconv_substr in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [libs/libphp5.bundle] Error 1



[2010-01-02 00:37:24] conrad dot tim at gmail dot com

This bug remains for me. On Snow Leapoard (10.6.2 Build 10C540) using 
php5.3-201001012330 snapshot).

Output ending the make process:
Undefined symbols:
  "_libiconv", referenced from:
  __php_iconv_strlen in iconv.o
  _php_iconv_string in iconv.o
  _php_iconv_string in iconv.o
  __php_iconv_strpos in iconv.o
  __php_iconv_appendl in iconv.o
  __php_iconv_appendl in iconv.o
  _zif_iconv_substr in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _zif_iconv_mime_encode in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
  _php_iconv_stream_filter_append_bucket in iconv.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [libs/libphp5.bundle] Error 1



[2009-12-30 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



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/49267

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



#50595 [Fbk->Opn]: Mysqlnd extension needs to read my.ini file for sanity

2010-01-02 Thread tallyce at gmail dot com
 ID:   50595
 User updated by:  tallyce at gmail dot com
 Reported By:  tallyce at gmail dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Feature/Change Request
 Operating System: Windows7
 PHP Version:  5.3.1
 New Comment:

In my case, the data files are too big to fit on the C: driver, so 
placing them in the MySQL subdirectory (under program files) is not an

option. So, the "datadir" setting in my.ini is set to be elsewhere. (In

the end I used a Windows7 symlink as a workaround, but this feels like
a 
rather unsatisfactory hack.)

I don't know which settings are still read by the MySQL server process,

but this one at least is ignored by PHP.

Either way, it seems odd that one should go through the process of 
setting up and tuning a MySQL server and then have the key program that

reads the data simply ignore the settings, following the release of PHP

5.3.x.


Previous Comments:


[2009-12-29 12:12:45] johan...@php.net

Which settings would you actually need to set for the client in my.cnf?
- The server will read it's settings anyways.



[2009-12-28 19:53:21] tallyce at gmail dot com

Description:

http://au2.php.net/manual/en/migration53.incompatible.php
states that the Mysqlnd driver doesn't read the my.ini file but 
instead that mysqli_options() should be used to tell PHP about 
settings.

Can I plead the developers to have a mysqlnd.inifile option or 
similar?

This latest change is very regressive: it means that, for instance, if

your database files are stored in a non-standard location, e.g. a data

rather than OS C: disk (as specified in my.ini), or any other 
performance-related setting, these all have to be manually added to 
script files, making them completely non-portable, or editing through 
third-party apps (making it time-consuming to upgrade).

If such an ini option were added, might it just be a case of just 
parsing the specified file and passing the found values into whatever 
interface mysqli_options is using?

Reproduce code:
---
n/a

Expected result:

n/a

Actual result:
--
n/a





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



#50635 [NEW]: Parse error occures if '?>' is put into a single-string comment

2010-01-02 Thread sergio at js-client dot com
From: sergio at js-client dot com
Operating system: 
PHP version:  5.3.1
PHP Bug Type: *General Issues
Bug description:  Parse error occures if '?>' is put into a single-string 
comment

Description:

Parse error (as unexpected $end) occures if '?>' is put into a
single-string comment

Reproduce code:
---


//preg_match_all('~(?>\s)=~s', $str);

   }
?>



Expected result:

No parsing errors

Actual result:
--
PHP Parse error:  syntax error, unexpected $end in /Users/apple/serg.php
on line 6

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



#50636 [NEW]: MySQLi_Result sets values before calling constructor

2010-01-02 Thread stein at rhrk dot uni-kl dot de
From: stein at rhrk dot uni-kl dot de
Operating system: 
PHP version:  5.2.12
PHP Bug Type: MySQLi related
Bug description:  MySQLi_Result sets values before calling constructor

Description:

MySQLi_Result::fetch_object sets properties before calling the
constructor, see BUG #49521

The behavior is similar to the one in BUG #49521 which has been fixed as
of PHP 5.2.12.

Note: It should be considered that this behavior may be not bug at all.
Calling the constructor BEFORE setting the properties (as done in BUG
#49521) leaves no possibility to work with the data at "construction time"
of the object.

Setting default properties could be done by assigning them in the
class-definition, but setting other properties depending on the loaded data
is hard to do, when this data is not yet available when the constructor is
called. This problem is even harder to solve, as no setters for the
properties are called, even if they are declared as private.

Reproduce code:
---
class Test
{

  private
$myprivate   = 0;

  function __construct()
  {
echo 'constructor called, $myprivate is ', $this->myprivate;
  }

  function __set ( $name, $value )
  {
echo 'setting ', $name, ' to ', $value;
$this->{$name}   = (int) $value;
  }

}

$mysqli->query('SELECT 1 AS myprivate, 2 AS
mypublic')->fetch_object('Test');


Expected result:

If the same way to handle this bug as in BUG #49521 is considered:

constructor called, $myprivate is 0
setting mypublic to 2

object(Test)#6 (2) {
  ["myprivate:private"]=>
  string(1) "1"
  ["mypublic"]=>
  int(2)
}

But maybe the following behavior would make more sense if it should be
changed:

constructor called, $myprivate is 0
setting myprivate to 1
setting mypublic to 2

object(Test)#6 (2) {
  ["myprivate:private"]=>
  int(1)
  ["mypublic"]=>
  int(2)
}




Actual result:
--
setting mypublic to 2
constructor called, $myprivate is 1

object(Test)#6 (2) {
  ["myprivate:private"]=>
  string(1) "1"
  ["mypublic"]=>
  int(2)
}


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



#50635 [Opn->Bgs]: Parse error occures if '?>' is put into a single-string comment

2010-01-02 Thread jani
 ID:  50635
 Updated by:  j...@php.net
 Reported By: sergio at js-client dot com
-Status:  Open
+Status:  Bogus
 Bug Type:*General Issues
 PHP Version: 5.3.1
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php




Previous Comments:


[2010-01-02 14:14:22] sergio at js-client dot com

Description:

Parse error (as unexpected $end) occures if '?>' is put into a
single-string comment

Reproduce code:
---


//preg_match_all('~(?>\s)=~s', $str);

   }
?>



Expected result:

No parsing errors

Actual result:
--
PHP Parse error:  syntax error, unexpected $end in
/Users/apple/serg.php on line 6





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



#50628 [Opn->Bgs]: Trailing slash in dirname

2010-01-02 Thread jani
 ID:   50628
 Updated by:   j...@php.net
 Reported By:  ninive at gmx dot at
-Status:   Open
+Status:   Bogus
 Bug Type: Directory function related
 Operating System: Linux 2.6.31
 PHP Version:  5.2.12
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

[j...@bfit ~]$ dirname /hugo/
/
[j...@bfit ~]$ dirname /hugo
/



Previous Comments:


[2010-01-01 19:11:29] ninive at gmx dot at

Description:

dirname("/hugo/") -> "/"

Reproduce code:
---
echo dirname("/hugo/")

Expected result:

"/hugo"

Actual result:
--
"/"





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



#50551 [Fbk->Opn]: mb_ereg + mb_eregi crash

2010-01-02 Thread r dot badding at gmail dot com
 ID:   50551
 User updated by:  r dot badding at gmail dot com
 Reported By:  r dot badding at gmail dot com
-Status:   Feedback
+Status:   Open
 Bug Type: mbstring related
 Operating System: win32 only - Windows XP
 PHP Version:  5.2.12
 New Comment:

Still getting the same crash with the snapshot php-5.2-win32-VC6-x86-
latest.

I made sure I had the correct extension dir in php.ini and no other 
php5ts.dll were found than the one in the snapshot. 

I think I haven't screwed up anything, but of course there's always
that 
possibility. Don't think so though.


Previous Comments:


[2009-12-30 14:43:24] j...@php.net

Please try using this snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

Try the snap. Maybe it was fixed as I can't reproduce this. And when
you reply, use the "Edit submission" tab!



[2009-12-30 13:42:16] r dot badding at gmail dot com

So, nobody can reproduce? The testcase is simple at least...



[2009-12-22 15:00:27] r dot badding at gmail dot com

By crash, I mean a dialog box like this:

---
Visual Studio Just-In-Time Debugger
---
An unhandled win32 exception occurred in Apache.exe [4804]. Just-In-
Time 
debugging this exception failed with the following error: No installed

debugger has Just-In-Time debugging enabled. In Visual Studio, Just-
In-
Time debugging can be enabled from Tools/Options/Debugging/Just-In-
Time.

Check the documentation index for 'Just-in-time debugging, errors' for

more information.
---
OK   
---


When I have eAccelerator enabled, instead of the dialog box I get 
these 
into the Apache's error.log:
EACCELERATOR: PHP crashed on opline 7 of mb_ereg()

Sure, the error might be in somewhere else than in php, maybe in 
Apache, 
or the api dll or anywhere...



[2009-12-22 09:05:53] j...@php.net

And regarding the password, you can find the password reminder link on
the "Edit Submission" tab..



[2009-12-22 09:05:06] j...@php.net

Please define "crash" ? Aren't you just running out of stack or
memory..? FYI: There is no crash on *nix..



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/50551

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



#48195 [Com]: iconv link failure

2010-01-02 Thread iongion at yahoo dot com
 ID:   48195
 Comment by:   iongion at yahoo dot com
 Reported By:  rickdunn at chez dot com
 Status:   Open
 Bug Type: Compile Failure
 Operating System: MacOSX 10.6.2
 PHP Version:  5.3.1
 Assigned To:  scottmac
 New Comment:

I think i found solution to this.
It is clearly the compiler or linker being upset.

I remove all traces of iconv from my computer (an osx) and of php (even
the default one that snow leopard comes with)

Then i installed a fresh iconv + compile fresh php 5.3.1

Everything worked.

I had lots of libiconv builds in my /usr/local/lib

(remember, i first deleted all traces of iconv or php, headers, so,
dylib, a)


Previous Comments:


[2009-12-22 15:10:49] rickdunn at chez dot com

I don't use 5.2.*, so this is just a 5.3.* issue for me.  Here's the 
output requested:

The grep results...

#define HAVE_ICONV 1
#define PHP_ICONV_IMPL "libiconv"
#define PHP_ICONV_IMPL "libiconv"
#define PHP_ICONV_IMPL "libiconv"
#define PHP_ICONV_IMPL "libiconv"
#define ICONV_SUPPORTS_ERRNO 1
#define ICONV_SUPPORTS_ERRNO 1
#define ICONV_SUPPORTS_ERRNO 1
#define PHP_ICONV_H_PATH 
#define HAVE_ICONV 1

And the cat results...

#define HAVE_ICONV 1
#define HAVE_LIBICONV 1
#define ICONV_SUPPORTS_ERRNO 1
#define PHP_ICONV_H_PATH 
#define PHP_ICONV_IMPL "libiconv"



[2009-12-22 14:37:33] j...@php.net

I deleted the irrelevant comments from this report, it was getting too
noisy. Now, is it still so that compiling PHP 5.2.12 works and only 5.3
fails?

Please show the output of these commands after running configure (for
the failed build :)

# grep ICONV main/php_config.h | grep define

and 

# cat php_have_bsd_iconv.h \
php_have_glibc_iconv.h \
php_have_ibm_iconv.h \
php_have_iconv.h \
php_have_libiconv.h \
php_iconv_supports_errno.h \
php_php_iconv_h_path.h \
php_php_iconv_impl.h




[2009-12-22 12:22:22] rickdunn at chez dot com

The snapshot make failed with the usual message. "Undefined symbols:
  "_libiconv", referenced from:", etc.



[2009-12-16 08:31:02] j...@php.net

That's just fixing a symptom, not the bug.



[2009-12-15 22:32:37] rickdunn at chez dot com

Apple has a patch for the PHP source iconv.c file that fixes this 
problem:

http://www.opensource.apple.com/source/apache_mod_php/apache_mod_php-
53/patches/iconv.patch



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/48195

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



#42060 [Com]: [PATCH] LDAP: Add pagedResults support and more

2010-01-02 Thread danhstevens at gmail dot com
 ID:   42060
 Comment by:   danhstevens at gmail dot com
 Reported By:  iarenuno at eteo dot mondragon dot edu
 Status:   Assigned
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  5CVS, 6CVS (2008-11-01)
 Assigned To:  patrickallaert
 New Comment:

Why is this patch still being overlooked? pajoye: You said there would
be a patch committed in a few days - that was well over a year ago and
as far as I can see nothing has been committed. Can we get this patch
pushed through? Is there any good reason this hasn't been implemented
yet? PLEASE tell us when to expect this patch, if ever.


Previous Comments:


[2009-12-17 14:36:28] chris at sogetthis dot com

Who is Alexey and where is the updated patch?



[2009-09-02 11:34:28] jochen at keutel dot de

I still can't see this patch in 5.3.x or HEAD; neither in PHP 6.

A lot of people really need this extension; e.g. when talking LDAP to
MS Active Directory you *need* the paged results control. Reason: AD
returns only 1000 entries without paging.

Another scenario often used is password policies; also her you
definitely need parsing of extended LDAP responses.

Please apply this patch !!!

Regards,  Jochen.



[2009-06-08 11:30:13] dj at krul dot nu

pajoye: I can't find the commit you're referring to (either in HEAD or
the 5.3 branch). Has it been committed yet?



[2009-06-05 15:31:40] paj...@php.net

>> get some help :)



[2008-11-16 14:57:56] paj...@php.net

Alexey has ported the patch to 5.3, it will committed in the next days.



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/42060

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



#50638 [NEW]: User Stream $context is Not Populated

2010-01-02 Thread cullin dot wible at cullinwible dot com
From: cullin dot wible at cullinwible dot com
Operating system: CentOS 5.4 x86_64
PHP version:  5.3.1
PHP Bug Type: *General Issues
Bug description:  User Stream $context is Not Populated

Description:

When creating a user stream using the streamWrapper format, the $context
variable is NOT set during the stream_open method call.


Reproduce code:
---
class TestStream {
public $context;

public function __construct() {
/* do nothing */
}

public function stream_open($path, $mode, $options, &$opened_path) {
echo "Open Context: ";
var_dump($context); 

return(true);
}
}

stream_wrapper_register('test, 'TestStream', 0);

$options = array(
'test' => array(
'option1' => 'option1_value'));

$myContext = stream_context_create($options);

fopen('test://test', 'r', false, $myContext);


Expected result:

the $this->context variable should equal $myContext.

Actual result:
--
The $this->context variable is NULL.

Please NOTE the following:

1. The $context is set on an fread, however, it should be set during the
fopen call.

2. If you look at the PHP-c-code, it appears that the userstream.c class
is attempting to set the $context property just after class construction
and prior to calling stream_open. Also, after modifying the C-code it
appears that the context in the C-code is defined and calls the Zend
add_property_resource function. However, there is clearly a bug somewhere
as the property is still NULL.

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



#50638 [Opn->Bgs]: User Stream $context is Not Populated

2010-01-02 Thread bjori
 ID:   50638
 Updated by:   bj...@php.net
 Reported By:  cullin dot wible at cullinwible dot com
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: CentOS 5.4 x86_64
 PHP Version:  5.3.1
 New Comment:

bj...@jessica:~$ php foobar.php 
Open Context: resource(5) of type (stream-context)

Fix your parse error and change $context to $this->context


Previous Comments:


[2010-01-02 23:10:26] cullin dot wible at cullinwible dot com

Description:

When creating a user stream using the streamWrapper format, the
$context variable is NOT set during the stream_open method call.


Reproduce code:
---
class TestStream {
public $context;

public function __construct() {
/* do nothing */
}

public function stream_open($path, $mode, $options, &$opened_path) {
echo "Open Context: ";
var_dump($context); 

return(true);
}
}

stream_wrapper_register('test, 'TestStream', 0);

$options = array(
'test' => array(
'option1' => 'option1_value'));

$myContext = stream_context_create($options);

fopen('test://test', 'r', false, $myContext);


Expected result:

the $this->context variable should equal $myContext.

Actual result:
--
The $this->context variable is NULL.

Please NOTE the following:

1. The $context is set on an fread, however, it should be set during
the fopen call.

2. If you look at the PHP-c-code, it appears that the userstream.c
class is attempting to set the $context property just after class
construction and prior to calling stream_open. Also, after modifying the
C-code it appears that the context in the C-code is defined and calls
the Zend add_property_resource function. However, there is clearly a bug
somewhere as the property is still NULL.





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



#50641 [NEW]: Extension directory

2010-01-02 Thread twallis at mts dot net
From: twallis at mts dot net
Operating system: Windows
PHP version:  5.2.12
PHP Bug Type: Performance problem
Bug description:  Extension directory

Description:

In the php.ini files included in the download the extensions directly is
set as: extension_dir = "./"

This prevents php from working.  It took me four hours of searching until
I tripped over documentation about extension_dir.  Once I chenged the line
to read: extension_dir = "c:/php/ext"  the problem was fixed.

Nowhere was it stated as part of the installation procedure to change this
line.

Reproduce code:
---
extension_dir = "./"

Expected result:

php preprocessing does not occur

Actual result:
--
php preprocessing does not occur

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