reverted HTTPCLient debug back to defaulted off

Dependencies:   HTTPClient-SSL

Fork of MTS-Socket by Keith Ruenheck

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers Socket.cpp Source File

Socket.cpp

00001 #include "Socket.h"
00002 #include <cstring>
00003 #include "Transport.h"
00004 
00005 Socket::Socket() : _blocking(true), _timeout(1500) {
00006     ip = Transport::getInstance();
00007 }
00008 
00009 void Socket::set_blocking(bool blocking, unsigned int timeout) {
00010     _blocking = blocking;
00011     _timeout = timeout;
00012 }
00013 
00014 int Socket::close(bool shutdown) {
00015     return (ip->close(shutdown)) ? 0 : -1;
00016 }
00017 
00018 Socket::~Socket() {
00019     close(true); //Don't want to leak
00020 }