# HG changeset patch # User Rob Landley # Date 1396394326 18000 # Node ID 1f4a56212c8383c066c462ac23276f17a574f1f8 # Parent 63db77909fc82525ffd9894dea5f98c849ba8bcb bugfix: the multiplexer increments optc and then the command the multiplexer runs increments it further, resulting in a wrong count. Fix: zero it. diff -r 63db77909fc8 -r 1f4a56212c83 main.c --- a/main.c Sat Mar 29 18:11:00 2014 -0500 +++ b/main.c Tue Apr 01 18:18:46 2014 -0500 @@ -132,6 +132,7 @@ toys.which = toy_list; if (toys.argv[1]) { + toys.optc = 0; toy_exec(toys.argv+1); if (toys.argv[1][0] == '-') goto list;