aboutsummaryrefslogtreecommitdiffstats
path: root/tests/testparse.cpp
diff options
context:
space:
mode:
authorGravatar Miika Turkia <miika.turkia@gmail.com>2017-05-04 21:22:41 +0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-05-06 08:06:42 -0700
commit52426b8585020214293b10e78f0b129b51141ca8 (patch)
tree146b862f35c6e19912c50addba94112b746255d9 /tests/testparse.cpp
parent0d36b6e4e8305699f35ee57ceae5a2a00f429195 (diff)
downloadsubsurface-52426b8585020214293b10e78f0b129b51141ca8.tar.gz
Fix memory leak
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Diffstat (limited to 'tests/testparse.cpp')
-rw-r--r--tests/testparse.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/testparse.cpp b/tests/testparse.cpp
index 7195af75a..ec47d3d27 100644
--- a/tests/testparse.cpp
+++ b/tests/testparse.cpp
@@ -60,7 +60,7 @@ int TestParse::parseCSV(int units, std::string file)
char *params[55];
int pnr = 0;
- params[pnr++] = strdup(strdup("numberField"));
+ params[pnr++] = strdup("numberField");
params[pnr++] = intdup(0);
params[pnr++] = strdup("dateField");
params[pnr++] = intdup(1);
@@ -411,7 +411,7 @@ int TestParse::parseCSVmanual(int units, std::string file)
char *params[55];
int pnr = 0;
- params[pnr++] = strdup(strdup("numberField"));
+ params[pnr++] = strdup("numberField");
params[pnr++] = intdup(0);
params[pnr++] = strdup("dateField");
params[pnr++] = intdup(1);