data[i] = 0;
ref_name = mid + 1;
ref = alloc_ref(ref_name);
- get_sha1_hex(start, ref->old_sha1);
+ get_oid_hex(start, &ref->old_oid);
if (!refs)
refs = ref;
if (last_ref)
if (posn->symref)
printf("@%s %s\n", posn->symref, posn->name);
else
- printf("%s %s\n", sha1_to_hex(posn->old_sha1), posn->name);
+ printf("%s %s\n", oid_to_hex(&posn->old_oid), posn->name);
}
printf("\n");
fflush(stdout);
if (options.depth)
die("dumb http transport does not support --depth");
for (i = 0; i < nr_heads; i++)
- targets[i] = xstrdup(sha1_to_hex(to_fetch[i]->old_sha1));
+ targets[i] = xstrdup(oid_to_hex(&to_fetch[i]->old_oid));
walker = get_http_walker(url.buf);
walker->get_all = 1;
if (!*ref->name)
die("cannot fetch by sha1 over smart http");
packet_buf_write(&preamble, "%s %s\n",
- sha1_to_hex(ref->old_sha1), ref->name);
+ oid_to_hex(&ref->old_oid), ref->name);
}
packet_buf_flush(&preamble);
die("protocol error: expected sha/ref, got %s'", p);
ref = alloc_ref(name);
- hashcpy(ref->old_sha1, old_sha1);
+ hashcpy(ref->old_oid.hash, old_sha1);
*list = ref;
list = &ref->next;