projects
/
fusionforge
/
fusionforge.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
project home
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
438e44d
)
reactivity: work-around getopt limitation
author
Sylvain Beucler
<sylvain.beucler@inria.fr>
Wed, 17 Dec 2014 17:54:52 +0000
(18:54 +0100)
committer
Sylvain Beucler
<sylvain.beucler@inria.fr>
Wed, 17 Dec 2014 17:54:52 +0000
(18:54 +0100)
src/bin/light.php
patch
|
blob
|
history
diff --git
a/src/bin/light.php
b/src/bin/light.php
index ce745b674a1229fa5b9907f468da7e4b3e65943d..2749132af8cc8ecbefae2ba528bdcd5e6bed45f4 100755
(executable)
--- a/
src/bin/light.php
+++ b/
src/bin/light.php
@@
-79,7
+79,7
@@
function sysaction_get_script($plugin_id, $sysaction_type_id) {
$shortopts = "v"; // enable verbose mode
$longopts = array();
$options = getopt($shortopts, $longopts);
-if (
$options === false) { // doesn't work, PHP returns ambiguous array() on error..
+if (
count($options) != (count($argv)-1)) { // PHP just strips invalid options
print "Usage: {$argv[0]} [-v]\n";
exit(1);
}