[Commits] : Tuxbox-GIT: apps branch master updated. CVS-Final-584-g77bc285
Tuxbox Sources
Brought to you by:
dbt1
From: GetAway <tux...@ne...> - 2015-06-01 10:29:13
|
Project "Tuxbox-GIT: apps": The branch, master has been updated via 77bc28568f4c142acbe789c6dc85c7211672a55e (commit) from 9329e5b0197328e27df0467d0ffc13242f0ee05a (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 77bc28568f4c142acbe789c6dc85c7211672a55e Author: GetAway <get...@t-...> Date: Mon Jun 1 12:28:37 2015 +0200 ysocket.cpp: fix warning len >= 0 is always true Signed-off-by: GetAway <get...@t-...> diff --git a/tuxbox/neutrino/daemons/nhttpd/yhttpd_core/ysocket.cpp b/tuxbox/neutrino/daemons/nhttpd/yhttpd_core/ysocket.cpp index 93e1ba6..1e23b08 100644 --- a/tuxbox/neutrino/daemons/nhttpd/yhttpd_core/ysocket.cpp +++ b/tuxbox/neutrino/daemons/nhttpd/yhttpd_core/ysocket.cpp @@ -66,6 +66,7 @@ CySocket::~CySocket() //----------------------------------------------------------------------------- void CySocket::init(void) { + BytesSend = 0; handling = false; isOpened = false; isValid = true; @@ -302,7 +303,7 @@ int CySocket::Send(char const *buffer, unsigned int length) else #endif len = ::send(sock, buffer, length, MSG_NOSIGNAL); - if(len >= 0) + if(len > 0) BytesSend += len; return len; } @@ -311,7 +312,7 @@ int CySocket::Send(char const *buffer, unsigned int length) //----------------------------------------------------------------------------- bool CySocket::CheckSocketOpen() { - char buffer[32]; + char buffer[32] = { 0 }; #ifdef CONFIG_SYSTEM_CYGWIN return !(recv(sock, buffer, sizeof(buffer), MSG_PEEK | MSG_NOSIGNAL) == 0); ----------------------------------------------------------------------- Summary of changes: .../daemons/nhttpd/yhttpd_core/ysocket.cpp | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) -- Tuxbox-GIT: apps |