Merge branch 'js/rebase-stat-unrelated-fix'
[gitweb.git] / builtin / am.c
index dc576a33728f5c2264acf66fcbe3243284144781..8f27f3375b1e92f2ef026e0a1530ca8b6b3235bf 100644 (file)
@@ -2113,7 +2113,9 @@ static int parse_opt_patchformat(const struct option *opt, const char *arg, int
 {
        int *opt_value = opt->value;
 
-       if (!strcmp(arg, "mbox"))
+       if (unset)
+               *opt_value = PATCH_FORMAT_UNKNOWN;
+       else if (!strcmp(arg, "mbox"))
                *opt_value = PATCH_FORMAT_MBOX;
        else if (!strcmp(arg, "stgit"))
                *opt_value = PATCH_FORMAT_STGIT;