Own fork of MbedSmartRest
Dependents: MbedSmartRestMain MbedSmartRestMain
Fork of MbedSmartRest by
Revision 26:9c36af176d91, committed 2015-08-10
- Comitter:
- xinlei
- Date:
- Mon Aug 10 10:39:53 2015 +0000
- Parent:
- 25:b8a080f5e578
- Commit message:
- removed traffic accounting
Changed in this revision
diff -r b8a080f5e578 -r 9c36af176d91 MbedClient.cpp --- a/MbedClient.cpp Mon Jun 01 12:56:26 2015 +0000 +++ b/MbedClient.cpp Mon Aug 10 10:39:53 2015 +0000 @@ -184,7 +184,6 @@ void MbedClient::stop() { - aInfo("\033[32mMbed:\033[39m %zu bytes sent.\n", packetSize); _isStreamRequest = false; _sock.close(); _source.reset();
diff -r b8a080f5e578 -r 9c36af176d91 MbedDataSink.cpp --- a/MbedDataSink.cpp Mon Jun 01 12:56:26 2015 +0000 +++ b/MbedDataSink.cpp Mon Aug 10 10:39:53 2015 +0000 @@ -33,7 +33,6 @@ #include "MbedClient.h" #include "logging.h" -size_t packetSize = 0; MbedDataSink::MbedDataSink(TCPSocketConnection& sock) : _sock(sock), _len(0) { @@ -51,7 +50,6 @@ } _buf[_len++] = c; - ++packetSize; return 1; } @@ -74,7 +72,6 @@ _len += len; sent += len; } - packetSize += length; return length; } @@ -86,8 +83,7 @@ size_t MbedDataSink::write(unsigned long number) { char str[24]; - - packetSize += snprintf(str, 24, "%lu", number); + snprintf(str, 24, "%lu", number); return write(str); }
diff -r b8a080f5e578 -r 9c36af176d91 MbedDataSink.h --- a/MbedDataSink.h Mon Jun 01 12:56:26 2015 +0000 +++ b/MbedDataSink.h Mon Aug 10 10:39:53 2015 +0000 @@ -36,7 +36,6 @@ #define MBED_SINK_BUFFER_SIZE 600 class MbedClient; -extern size_t packetSize; class MbedDataSink : public AbstractDataSink {