Merge pull request #7005 from hwware/memoryleakfix-redis-cli

fix potential memory leak in redis-cli lua debug mode
This commit is contained in:
Salvatore Sanfilippo 2020-03-23 11:14:46 +01:00 committed by GitHub
commit b9e5be5f56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1993,6 +1993,8 @@ static void repl(void) {
if (config.eval) {
config.eval_ldb = 1;
config.output = OUTPUT_RAW;
sdsfreesplitres(argv,argc);
linenoiseFree(line);
return; /* Return to evalMode to restart the session. */
} else {
printf("Use 'restart' only in Lua debugging mode.");