From: Junio C Hamano Date: Sun, 20 May 2007 09:18:47 +0000 (-0700) Subject: Merge branch 'sv/checkout' X-Git-Tag: v1.5.3-rc0~217 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/063581e9b648b4da3b83061b06aed7ed417411e0?ds=inline;hp=-c Merge branch 'sv/checkout' * sv/checkout: git-update-ref: add --no-deref option for overwriting/detaching ref --- 063581e9b648b4da3b83061b06aed7ed417411e0 diff --combined builtin-fetch--tool.c index 12adb3833c,b14e78ac3f..ed4d5de5d5 --- a/builtin-fetch--tool.c +++ b/builtin-fetch--tool.c @@@ -6,11 -6,11 +6,11 @@@ static char *get_stdin(void) { - int offset = 0; + size_t offset = 0; char *data = xmalloc(CHUNK_SIZE); while (1) { - int cnt = xread(0, data + offset, CHUNK_SIZE); + ssize_t cnt = xread(0, data + offset, CHUNK_SIZE); if (cnt < 0) die("error reading standard input: %s", strerror(errno)); @@@ -42,7 -42,7 +42,7 @@@ static int update_ref(const char *actio if (!rla) rla = "(reflog update)"; snprintf(msg, sizeof(msg), "%s: %s", rla, action); - lock = lock_any_ref_for_update(refname, oldval); + lock = lock_any_ref_for_update(refname, oldval, 0); if (!lock) return 1; if (write_ref_sha1(lock, sha1, msg) < 0)