wxHTTP::GetResponse() added (patch 794394)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23762 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2003-09-20 23:55:32 +00:00
parent 9473e9a437
commit 2e622163d0
4 changed files with 19 additions and 1 deletions

View File

@@ -44,6 +44,7 @@ wxHTTP::wxHTTP()
m_read = FALSE;
m_proxy_mode = FALSE;
m_post_buf = wxEmptyString;
m_http_response = 0;
SetNotify(wxSOCKET_LOST_FLAG);
}
@@ -213,6 +214,8 @@ bool wxHTTP::BuildRequest(const wxString& path, wxHTTP_Req req)
return FALSE;
}
m_http_response = 0;
// If there is no User-Agent defined, define it.
if (GetHeader(wxT("User-Agent")).IsNull())
SetHeader(wxT("User-Agent"), wxT("wxWindows 2.x"));
@@ -256,6 +259,8 @@ bool wxHTTP::BuildRequest(const wxString& path, wxHTTP_Req req)
token.NextToken();
tmp_str2 = token.NextToken();
m_http_response = wxAtoi(tmp_str2);
switch (tmp_str2[0u]) {
case wxT('1'):
/* INFORMATION / SUCCESS */