summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeServerLib/testServerBuffering.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/CMakeServerLib/testServerBuffering.cpp')
-rw-r--r--Tests/CMakeServerLib/testServerBuffering.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/Tests/CMakeServerLib/testServerBuffering.cpp b/Tests/CMakeServerLib/testServerBuffering.cpp
index 97be891..7330ead 100644
--- a/Tests/CMakeServerLib/testServerBuffering.cpp
+++ b/Tests/CMakeServerLib/testServerBuffering.cpp
@@ -1,7 +1,6 @@
#include "cmConnection.h"
#include "cmServerConnection.h"
#include <iostream>
-#include <stddef.h>
#include <string>
#include <vector>
@@ -51,8 +50,8 @@ int testServerBuffering(int, char** const)
std::unique_ptr<cmConnectionBufferStrategy>(new cmServerBufferStrategy);
std::vector<std::string> response;
std::string rawBuffer;
- for (size_t i = 0; i < fullMessage.size(); i++) {
- rawBuffer += fullMessage[i];
+ for (auto& messageChar : fullMessage) {
+ rawBuffer += messageChar;
std::string packet = bufferingStrategy->BufferMessage(rawBuffer);
do {
if (!packet.empty() && packet != "\r\n") {