]> cloudbase.mooo.com Git - z180-stamp.git/blobdiff - avr/cmd_gpio.c
reset optind before executing command
[z180-stamp.git] / avr / cmd_gpio.c
index 65a71bec864687ae1d24672b0d7fc096683ce162..549654fdf1c6e24da59512d87bff73ab2d71ba11 100644 (file)
@@ -173,9 +173,6 @@ command_ret_t do_gpio(cmd_tbl_t *cmdtp UNUSED, uint_fast8_t flag UNUSED, int arg
        uint_fast8_t pinarg[GPIO_MAX];
        uint_fast8_t pinargc;
 
-       /* reset getopt() */
-       optind = 0;
-
        int opt;
        while ((opt = getopt(argc, argv, PSTR("s"))) != -1) {
                switch (opt) {