1--TEST--
2Bug #43293 (Multiple segfaults in getopt())
3--INI--
4register_argc_argv=Off
5--FILE--
6<?php
7$argv = array(1, 2, 3);
8var_dump(getopt("abcd"));
9var_dump($argv);
10$argv = null;
11var_dump(getopt("abcd"));
12?>
13--EXPECT--
14array(0) {
15}
16array(3) {
17  [0]=>
18  int(1)
19  [1]=>
20  int(2)
21  [2]=>
22  int(3)
23}
24bool(false)
25
26