ref: 24abe6c00b6f65e7241763399fc72c043b7d9bbf
parent: 1f96d01edb9d306664cd803e7a0ff396b06b3705
author: Ori Bernstein <[email protected]>
date: Thu Sep 10 11:15:26 EDT 2020
git/serve, idxpack:fix copy-paste error (thanks rod)
--- a/pack.c
+++ b/pack.c
@@ -1044,7 +1044,6 @@
Bseek(f, o->off + o->len, 0);
if (r == -1)
continue;
- Bseek(f, o->off + o->len, 0);
sha1((uchar*)o->all, o->size + strlen(o->all) + 1, o->hash.h, nil);
valid[i] = 1;
cache(o);
--- a/serve.c
+++ b/serve.c
@@ -284,7 +284,7 @@
Hash h;
snprint(packtmp, sizeof(packtmp), ".git/objects/pack/recv-%d.pack.tmp", getpid());
- snprint(packtmp, sizeof(packtmp), ".git/objects/pack/recv-%d.idx.tmp", getpid());
+ snprint(idxtmp, sizeof(idxtmp), ".git/objects/idx/recv-%d.idx.tmp", getpid());
if((pfd = create(packtmp, ORDWR, 0644)) == -1)
return -1;
packsz = 0;