# Bugfix #21918

- Thread: https://externals.io/message/3866
- Original archive: https://news-web.php.net/php.internals/3866
- Started by Zeev Suraski on 2003-08-12T06:27:18+00:00
- Messages: 2
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #3866 — Zeev Suraski — 2003-08-12T06:27:18+00:00

URL: https://externals.io/message/3866#3866

At 05:16 11/08/2003, Ilia Alshanetsky wrote:
>+1
>
>This patch not only fixes the above mentioned bugs, but also serveral
>backwards compatibility issues that occured due to the fix for bug #18140.

Can you provide an example?

Zeev

---

## #3868 — Ilia Alshanetsky — 2003-08-12T12:39:25+00:00

URL: https://externals.io/message/3866#3868 · In reply to: #3866

> At 05:16 11/08/2003, Ilia Alshanetsky wrote:
> > […]
>
> Can you provide an example?

Original Bugs that caused BC break.
php -r ' $arr = array(0=>0,-1=>0); $arr[] = 0; '
This caused a segmentation fault in 4.2.3

Here is one example of the problem.
php -r ' $arr[-2] = 1; $arr[] = 2; print_r($arr); '
PHP 4.2.3
Array
(
    [-2] => 1
    [-1] => 2
)

PHP 4.3.X/5.X (wo/patch)
Array
(
    [-2] => 1
    [0] => 2
)

PHP 4.3.X/5.X (w/patch)
Array
(
    [-2] => 1
    [-1] => 2
)

Ilia
