Own fork of MbedSmartRest

Dependents:   MbedSmartRestMain MbedSmartRestMain

Fork of MbedSmartRest by Cumulocity Official

Revision:
26:9c36af176d91
Parent:
20:505d29d5bdfc
--- 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);
 }