Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Herland <johan@herland.net>2007-05-15 16:49:22 +0400
committerJunio C Hamano <junkio@cox.net>2007-05-16 08:16:03 +0400
commit8a912bcb250d8bf57b225e1cf02c0d69d54c8920 (patch)
tree51c2ec028d037343a67d99d891e1d01ad736e69e /builtin-fetch--tool.c
parent2924415f4fb081d9dde687092248c86ec0c40195 (diff)
Ensure return value from xread() is always stored into an ssize_t
This patch fixes all calls to xread() where the return value is not stored into an ssize_t. The patch should not have any effect whatsoever, other than putting better/more appropriate type names on variables. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-fetch--tool.c')
-rw-r--r--builtin-fetch--tool.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin-fetch--tool.c b/builtin-fetch--tool.c
index 2065466f27..12adb3833c 100644
--- a/builtin-fetch--tool.c
+++ b/builtin-fetch--tool.c
@@ -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));