Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of HTTPClient by
Diff: HTTPClient.cpp
- Revision:
- 21:6e5c122ad9e5
- Parent:
- 20:bbbfaf4cc055
- Child:
- 23:1a0d4d70f72c
--- a/HTTPClient.cpp Tue Nov 08 17:21:42 2016 +0000 +++ b/HTTPClient.cpp Fri Nov 11 16:13:48 2016 +0000 @@ -45,11 +45,10 @@ #define MAX_VALUE 64 #include <cstring> - #include "HTTPClient.h" -HTTPClient::HTTPClient(HTTPWiFi & _m_sock) : m_sock(_m_sock) -{ +HTTPClient::HTTPClient(NetworkStack & _m_intf) : m_intf(_m_intf) +{ } HTTPClient::~HTTPClient() @@ -147,8 +146,7 @@ DBG("Port: %d", port); DBG("Path: %s", path); // Open - m_sock.open(&m_sock.getWiFi()); - + m_sock.open(&m_intf); //Connect DBG("Connecting socket to server"); int ret = m_sock.connect(host, port); @@ -172,7 +170,6 @@ ERR("Could not write request"); return HTTP_CONN; } - //Send all headers //Send default headers