From d67b4765ea6ebc86f9f42b189ad8eb78dc84d83a Mon Sep 17 00:00:00 2001 From: Dhanya Thattil Date: Mon, 17 Sep 2018 12:32:33 +0200 Subject: [PATCH] Removing redundant null byte from end of json header --- slsReceiverSoftware/include/ZmqSocket.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/slsReceiverSoftware/include/ZmqSocket.h b/slsReceiverSoftware/include/ZmqSocket.h index d1773099e..05351b214 100644 --- a/slsReceiverSoftware/include/ZmqSocket.h +++ b/slsReceiverSoftware/include/ZmqSocket.h @@ -285,7 +285,7 @@ public: //additional stuff "\"flippedDataX\":%u" - ;//"}\n\0"; + ;//"}\n"; int length = sprintf(buf, jsonHeaderFormat, jsonversion, dynamicrange, fileIndex, npixelsx, npixelsy, imageSize, acqIndex, fIndex, (fname == NULL)? "":fname, dummy?0:1, @@ -298,9 +298,9 @@ public: ((flippedData == 0 ) ? 0 :flippedData[0]) ); if (additionalJsonHeader && strlen(additionalJsonHeader)) { - length = sprintf(buf, "%s, %s}\n%c", buf, additionalJsonHeader, '\0'); + length = sprintf(buf, "%s, %s}\n", buf, additionalJsonHeader); } else { - length = sprintf(buf, "%s}\n%c", buf, '\0'); + length = sprintf(buf, "%s}\n", buf); } #ifdef VERBOSE