Commit 1a41c73a authored by Andreas Schmidt's avatar Andreas Schmidt

Free buffer.

parent 37681fe7
Pipeline #2096 failed with stages
in 22 seconds
......@@ -115,8 +115,8 @@ int main(int argc, char **argv) {
s = _open(false, &arguments);
uint32_t i = 0;
char* buffer = calloc(arguments.size + 1, sizeof(char));
while (i < rounds && keepRunning) {
char* buffer = calloc(arguments.size + 1, sizeof(char));
debug(DEBUG_RECEIVER, "About to receive.");
int n = _recv(s, buffer, arguments.size);
if (n < 0) {
......@@ -136,6 +136,7 @@ int main(int argc, char **argv) {
rtts2[round] = timedelta(&now, old);
i++;
}
free(buffer);
for (i = 0; i < rounds; i++) {
fprintf(out_desc, "%u, %lli, %lli\n", i, rtts[i], rtts2[i]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment