Bug #62112: restore PHP 5.3 behavior #87

Closed
wants to merge 1 commit into
from

Projects

None yet

4 participants

@lstrojny
Contributor
@cataphract
Contributor

I don't think this fix is correct. The way to specify no separator is to pass an empty string. Yes, in PHP 5.3 specifying \0 has the same effect, but that's because the separator was a char type in 5.3 and \0 was the way to signal "no separator". This seems more like an artifact of a non-optimal implementation (never documented by way, and actually contrary to the documentation, which makes no reference to special treatment for NUL) and I see no reason to perpetuate such a behavior.

@php-pulls

Comment on behalf of cataphract at php.net:

Fixed by making the function binary safe instead

@php-pulls php-pulls closed this May 23, 2012
@lstrojny
Contributor

Thanks!

@nmmmnu
nmmmnu commented Jul 2, 2012

The official release did not worked for me, however your patch was OK.
However I did not compiled everything, I pull only the math.c file from the official release.

Thanks

@php-pulls php-pulls pushed a commit that referenced this pull request Jun 3, 2014
@bwoebi bwoebi Fixed startup segfault in non-debug builds
Fixes issue #87
467b19a
@php-pulls php-pulls pushed a commit that referenced this pull request Jun 3, 2014
@bwoebi bwoebi Fixed startup segfault in non-debug builds
Fixes issue #87
a1b0ae4
@Tyrael Tyrael added a commit that referenced this pull request Jun 4, 2014
@Tyrael Tyrael Merge branch 'PHP-5.6' into PHP-5.6.0
* PHP-5.6: (51 commits)
  Fix tests
  Fix possible segfault depending on memory location...
  fix gcov data with some locales (again)
  Update NEWS
  Fixed startup segfault in non-debug builds Fixes issue #87
  Fixed regression introduced by patch for bug #67072
  Fixed bug #67329 fileinfo: NULL pointer deference flaw by processing certain CDF files
  (re)add cve number in NEWS, from 5.4.29
  NEWS
  NEWS
  NEWS
  Fix bug #67326	fileinfo: cdf_read_short_sector insufficient boundary check
  add NEWS block for 5.6.0RC1
  Update NEWs
  Update NEWs
  Fixed bug #67359 (Segfault in recursiveDirectoryIterator)
  Check for zero-length keys in spl_array_skip_protected and don't skip them.
  added CVEs in NEWS
  updated libmagic.patch for 5.6+
  updated libmagic.patch for 5.4+
  ...

Conflicts:
	NEWS
4ed1713
@php-pulls php-pulls pushed a commit that referenced this pull request Jun 5, 2014
@dstogov dstogov Merge branch 'master' into phpng
* master: (29 commits)
  drop exec perm on doc files
  fix test for 5.4/5.5
  restore correct behavior of DateTime
  fix test use invalid code
  add test for previous fix
  NEWS
  NEWS
  NEWS
  Fix regression introduce in fix for bug #67118
  update news
  update NEWS
  Fix tests
  Fix possible segfault depending on memory location...
  Fixed startup segfault in non-debug builds Fixes issue #87
  PHP 5.4/5.5 compability in phpdbg_watch.c
  fix gcov data with some locales (again)
  fix gcov data with some locales (again)
  fix gcov data with some locales (again)
  Update NEWS
  Fixed startup segfault in non-debug builds Fixes issue #87
  ...
7178397
@php-pulls php-pulls pushed a commit that referenced this pull request Jun 6, 2014
@weltling weltling Merge remote-tracking branch 'origin/PHP-5.6' into str_size_and_int64…
…_56_backport

* origin/PHP-5.6: (24 commits)
  drop exec perm on doc files
  fix test for 5.4/5.5
  add test for previous fix
  NEWS
  NEWS
  NEWS
  Fix regression introduce in fix for bug #67118
  update news
  update NEWS
  Fix tests
  Fix possible segfault depending on memory location...
  fix gcov data with some locales (again)
  fix gcov data with some locales (again)
  Update NEWS
  Fixed startup segfault in non-debug builds Fixes issue #87
  Fixed regression introduced by patch for bug #67072
  Fixed bug #67329 fileinfo: NULL pointer deference flaw by processing certain CDF files
  (re)add cve number in NEWS, from 5.4.29
  NEWS
  NEWS
  ...

Conflicts:
	ext/date/php_date.c
d4cfc15
@php-pulls php-pulls pushed a commit that referenced this pull request Jun 6, 2014
@weltling weltling Merge remote-tracking branch 'origin/str_size_and_int64_56_backport' …
…into str_size_and_int64

* origin/str_size_and_int64_56_backport: (35 commits)
  drop exec perm on doc files
  fix test for 5.4/5.5
  add test for previous fix
  NEWS
  NEWS
  NEWS
  Fix regression introduce in fix for bug #67118
  update news
  update NEWS
  Fix tests
  Fix possible segfault depending on memory location...
  fix gcov data with some locales (again)
  fix gcov data with some locales (again)
  Update NEWS
  Fixed startup segfault in non-debug builds Fixes issue #87
  Fixed regression introduced by patch for bug #67072
  Fixed bug #67329 fileinfo: NULL pointer deference flaw by processing certain CDF files
  (re)add cve number in NEWS, from 5.4.29
  NEWS
  NEWS
  ...
df07944
@php-pulls php-pulls pushed a commit that referenced this pull request Jun 6, 2014
@weltling weltling Merge remote-tracking branch 'origin/master' into str_size_and_int64
* origin/master:
  restore correct behavior of DateTime
  fix test use invalid code
  Fixed startup segfault in non-debug builds Fixes issue #87
  PHP 5.4/5.5 compability in phpdbg_watch.c
  fix gcov data with some locales (again)

Conflicts:
	ext/date/php_date.c
0e7bf92
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment