gpg-interface: move parse_signature() to where it should be
[gitweb.git] / send-pack.c
index 6dc8a460c2165756d839788d98f42d5121dc4ff6..bb13599c33f2cbf423bd0f4d4c1615364f0cb859 100644 (file)
@@ -304,15 +304,16 @@ int send_pack(struct send_pack_args *args,
 
                old_hex = sha1_to_hex(ref->old_sha1);
                new_hex = sha1_to_hex(ref->new_sha1);
-               if (!cmds_sent)
+               if (!cmds_sent) {
                        packet_buf_write(&req_buf,
                                         "%s %s %s%c%s",
                                         old_hex, new_hex, ref->name, 0,
                                         cap_buf.buf);
-               else
+                       cmds_sent = 1;
+               } else {
                        packet_buf_write(&req_buf, "%s %s %s",
                                         old_hex, new_hex, ref->name);
-               cmds_sent++;
+               }
        }
 
        if (args->stateless_rpc) {