Do not output "GEN " when generating perl.mak
[gitweb.git] / revision.c
index 35a171105a28ce10fdef58c46efdd73cd113dd50..3c2eb125e6e9332fe32be9bcec6fb2005228c211 100644 (file)
@@ -1247,7 +1247,7 @@ static void gc_boundary(struct object_array *array)
                                objects[j] = objects[i];
                        j++;
                }
-               for (i = j; j < nr; j++)
+               for (i = j; i < nr; i++)
                        objects[i].item = NULL;
                array->nr = j;
        }
@@ -1301,13 +1301,14 @@ struct commit *get_revision(struct rev_info *revs)
        /*
         * Now pick up what they want to give us
         */
-       if (!(c = get_revision_1(revs)))
-               return NULL;
-       while (0 < revs->skip_count) {
-               revs->skip_count--;
-               c = get_revision_1(revs);
-               if (!c)
-                       break;
+       c = get_revision_1(revs);
+       if (c) {
+               while (0 < revs->skip_count) {
+                       revs->skip_count--;
+                       c = get_revision_1(revs);
+                       if (!c)
+                               break;
+               }
        }
 
        /*
@@ -1317,7 +1318,6 @@ struct commit *get_revision(struct rev_info *revs)
        case -1:
                break;
        case 0:
-               /* Although we grabbed it, it is not shown. */
                c = NULL;
                break;
        default: