Code

test smart http fetch and push
[git.git] / builtin-fetch.c
index 817dd6bff0bf0ddc9a3d00191bb3c422300b878b..52a9a42fa52948c1ab04a6965a3814d287949740 100644 (file)
@@ -454,7 +454,7 @@ static int quickfetch(struct ref *ref_map)
 
        for (ref = ref_map; ref; ref = ref->next) {
                if (write_in_full(revlist.in, sha1_to_hex(ref->old_sha1), 40) < 0 ||
-                   write_in_full(revlist.in, "\n", 1) < 0) {
+                   write_str_in_full(revlist.in, "\n") < 0) {
                        if (errno != EPIPE && errno != EINVAL)
                                error("failed write to rev-list: %s", strerror(errno));
                        err = -1;
@@ -665,7 +665,7 @@ int cmd_fetch(int argc, const char **argv, const char *prefix)
 
        transport = transport_get(remote, remote->url[0]);
        if (verbosity >= 2)
-               transport->verbose = 1;
+               transport->verbose = verbosity <= 3 ? verbosity : 3;
        if (verbosity < 0)
                transport->verbose = -1;
        if (upload_pack)