Make git-remote a builtin
[gitweb.git] / parse-options.c
index d9562ba5047ff1c9994755a4dbec5162b551c788..be35785ce88e03d23ca5b0e5ffdc6142fb931060 100644 (file)
@@ -249,6 +249,8 @@ int parse_options(int argc, const char **argv, const struct option *options,
                const char *arg = args.argv[0];
 
                if (*arg != '-' || !arg[1]) {
+                       if (flags & PARSE_OPT_STOP_AT_NON_OPTION)
+                               break;
                        argv[j++] = args.argv[0];
                        continue;
                }