diff options
author | Alex Gorrod <alexg@wiredtiger.com> | 2014-04-16 16:06:20 +1000 |
---|---|---|
committer | Alex Gorrod <alexg@wiredtiger.com> | 2014-04-16 16:06:20 +1000 |
commit | 7480ac78fc7e228cde7e22654e971d1f54fdba95 (patch) | |
tree | 1875aac4821c9c453e5cee218f57728a2b635e19 /test | |
parent | d94b04a14b5c0104b405d65ebe5bbc337db8c3f0 (diff) | |
download | mongo-7480ac78fc7e228cde7e22654e971d1f54fdba95.tar.gz |
Don't double free in checkpoint test
Diffstat (limited to 'test')
-rw-r--r-- | test/checkpoint/test_checkpoint.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/checkpoint/test_checkpoint.c b/test/checkpoint/test_checkpoint.c index 4a34370a766..55ecc14df2f 100644 --- a/test/checkpoint/test_checkpoint.c +++ b/test/checkpoint/test_checkpoint.c @@ -153,6 +153,7 @@ main(int argc, char *argv[]) } free(g.cookies); + g.cookies = NULL; if ((ret = wt_shutdown()) != 0) { (void)log_print_err("Start workers failed", ret, 1); break; @@ -166,7 +167,8 @@ main(int argc, char *argv[]) */ if (ret != 0) { (void)wt_shutdown(); - free(g.cookies); + if (g.cookies != NULL) + free(g.cookies); } return (0); } |