From c3e34ee81af71c70514d53f4e54e3a6c2ac5a976 Mon Sep 17 00:00:00 2001 From: Tycho Bickerstaff Date: Sun, 22 Dec 2013 17:02:36 +0000 Subject: removed unneccisary cast --- src/ByteBuffer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ByteBuffer.cpp b/src/ByteBuffer.cpp index 510018005..e06f63a0e 100644 --- a/src/ByteBuffer.cpp +++ b/src/ByteBuffer.cpp @@ -781,7 +781,8 @@ bool cByteBuffer::ReadToByteBuffer(cByteBuffer & a_Dst, size_t a_NumBytes) return false; } char buf[1024]; - while (a_NumBytes > static_cast(0)) + // > 0 without generating warnings about unsigned comparisons where size_t is unsigned + while (a_NumBytes != 0) { size_t num = (a_NumBytes > sizeof(buf)) ? sizeof(buf) : a_NumBytes; VERIFY(ReadBuf(buf, num)); -- cgit v1.2.3