author | Nicolas Kaiser <nikai@nikai.net> | |
Fri, 4 Mar 2011 23:16:26 +0000 (00:16 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Wed, 9 Mar 2011 05:36:12 +0000 (21:36 -0800) | ||
commit | 803dbdb9686f249e88fae8530b5306d6eea62c1b | |
tree | 82393f1d452d30a5e6cf2d4cc662c2ac3968f099 | tree | snapshot |
parent | 07873dc5dd67398324278ff0d7627bb1a863ba89 | commit | diff |
transport-helper.c: fix check for (size_t < 0)
'bytes' is of type size_t which is unsigned thus can't be negative. But
the assigned write() returns ssize_t, and -1 on error.
For testing < 0, 'bytes' needs to be of a signed type.
Signed-off-by: Nicolas Kaiser <nikai@nikai.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
'bytes' is of type size_t which is unsigned thus can't be negative. But
the assigned write() returns ssize_t, and -1 on error.
For testing < 0, 'bytes' needs to be of a signed type.
Signed-off-by: Nicolas Kaiser <nikai@nikai.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
transport-helper.c | diff | blob | history |