From f668749377dc53900b58f6a6645891b0ba0adef3 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 23 Jan 2013 11:44:30 +0000 Subject: [PATCH] Initialize all wxHTTPStream members in ctor. Don't leave m_httpsize and m_read_bytes uninitialized. Closes #14993. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73436 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/http.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/common/http.cpp b/src/common/http.cpp index f70b6fe9da..556618aca5 100644 --- a/src/common/http.cpp +++ b/src/common/http.cpp @@ -477,7 +477,13 @@ public: size_t m_httpsize; unsigned long m_read_bytes; - wxHTTPStream(wxHTTP *http) : wxSocketInputStream(*http), m_http(http) {} + wxHTTPStream(wxHTTP *http) : wxSocketInputStream(*http) + { + m_http = http; + m_httpsize = 0; + m_read_bytes = 0; + } + size_t GetSize() const { return m_httpsize; } virtual ~wxHTTPStream(void) { m_http->Abort(); } -- 2.45.2