From 28eaa574fddae4d5eb0f6af2b7a69fea72ef8044 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Tue, 23 Feb 2010 14:19:19 +0000 Subject: [PATCH] Fixed warning. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35586 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/add-ons/kernel/drivers/tty/tty.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/add-ons/kernel/drivers/tty/tty.cpp b/src/add-ons/kernel/drivers/tty/tty.cpp index 3957ab0d1e..563d6a7dbe 100644 --- a/src/add-ons/kernel/drivers/tty/tty.cpp +++ b/src/add-ons/kernel/drivers/tty/tty.cpp @@ -1851,7 +1851,8 @@ tty_input_read(tty_cookie* cookie, void* _buffer, size_t* _length) buffer += bytesRead; length -= bytesRead; *_length += bytesRead; - bytesNeeded = bytesRead > bytesNeeded ? 0 : bytesNeeded - bytesRead; + bytesNeeded = (size_t)bytesRead > bytesNeeded + ? 0 : bytesNeeded - bytesRead; // we hit an EOF char -- bail out, whatever amount of data we have if (hitEOF && *hitEOF) {