diff options
| author | Michael Grunder <michael.grunder@gmail.com> | 2019-10-08 10:55:15 -0700 | 
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-10-08 10:55:15 -0700 | 
| commit | 18eeeed0769bc669e3d9bb87e887157e7298da92 (patch) | |
| tree | 78c713bd7ed2b4756d52725033b5716e8997ecd8 | |
| parent | 01535274441bf235dc17ace1343515755a6049ed (diff) | |
| parent | 5aa7b1056b6b52e69d5e37baee97fddeebf184d3 (diff) | |
| download | hiredict-18eeeed0769bc669e3d9bb87e887157e7298da92.tar.xz | |
Merge pull request #715 from redis/test-leaks
Fixes leaks in unit tests
| -rw-r--r-- | test.c | 4 | 
1 files changed, 2 insertions, 2 deletions
| @@ -269,14 +269,14 @@ static void test_format_commands(void) {      sds sds_cmd; -    sds_cmd = sdsempty(); +    sds_cmd = NULL;      test("Format command into sds by passing argc/argv without lengths: ");      len = redisFormatSdsCommandArgv(&sds_cmd,argc,argv,NULL);      test_cond(strncmp(sds_cmd,"*3\r\n$3\r\nSET\r\n$3\r\nfoo\r\n$3\r\nbar\r\n",len) == 0 &&          len == 4+4+(3+2)+4+(3+2)+4+(3+2));      sdsfree(sds_cmd); -    sds_cmd = sdsempty(); +    sds_cmd = NULL;      test("Format command into sds by passing argc/argv with lengths: ");      len = redisFormatSdsCommandArgv(&sds_cmd,argc,argv,lens);      test_cond(strncmp(sds_cmd,"*3\r\n$3\r\nSET\r\n$7\r\nfoo\0xxx\r\n$3\r\nbar\r\n",len) == 0 && | 
