aboutsummaryrefslogtreecommitdiff
path: root/pack-objects.c
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2006-04-03 23:43:16 -0700
committerJunio C Hamano <junkio@cox.net>2006-04-03 23:43:16 -0700
commit7941602983f68e2cddafca5a2da8215d1271742b (patch)
tree215c42d1a96d25e08602afa47a211fd79ad7da67 /pack-objects.c
parent1bdbb57407ca28abce3fb731d01bfcbe74a9734a (diff)
parent72fdfb50f721460e4cdff16fbe9c72d4ce6c668c (diff)
downloadgit-7941602983f68e2cddafca5a2da8215d1271742b.tar.xz
Merge branch 'lt/fix-sol-pack' into next
* lt/fix-sol-pack: Use sigaction and SA_RESTART in read-tree.c; add option in Makefile. safe_fgets() - even more anal fgets()
Diffstat (limited to 'pack-objects.c')
-rw-r--r--pack-objects.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/pack-objects.c b/pack-objects.c
index 0ea16ad67f..d7ba938af7 100644
--- a/pack-objects.c
+++ b/pack-objects.c
@@ -1118,9 +1118,10 @@ int main(int argc, char **argv)
break;
if (!ferror(stdin))
die("fgets returned NULL, not EOF, not error!");
- if (errno == EINTR)
- continue;
- die("fgets: %s", strerror(errno));
+ if (errno != EINTR)
+ die("fgets: %s", strerror(errno));
+ clearerr(stdin);
+ continue;
}
if (line[0] == '-') {