use st_add and st_mult for allocation size computation
[gitweb.git] / http.c
diff --git a/http.c b/http.c
index 7d4cb2d4483524ce7b5b02cd324424f0c740ad02..0da9e6639832a493f932e3ba332683d3d4ae73ae 100644 (file)
--- a/http.c
+++ b/http.c
@@ -1402,7 +1402,7 @@ int http_fetch_ref(const char *base, struct ref *ref)
        if (http_get_strbuf(url, &buffer, &options) == HTTP_OK) {
                strbuf_rtrim(&buffer);
                if (buffer.len == 40)
-                       ret = get_sha1_hex(buffer.buf, ref->old_sha1);
+                       ret = get_oid_hex(buffer.buf, &ref->old_oid);
                else if (starts_with(buffer.buf, "ref: ")) {
                        ref->symref = xstrdup(buffer.buf + 5);
                        ret = 0;