diff options
author | Huang Zhw <huang_zhw@126.com> | 2021-07-19 16:10:25 +0800 |
---|---|---|
committer | Oran Agra <oran@redislabs.com> | 2021-07-21 21:06:49 +0300 |
commit | 68661171940480ff9bfa55936ceab2ae252340f0 (patch) | |
tree | 681d4c584975f8b288bebab18d89e0a7af1d76e5 | |
parent | b6225371998e928c098b6a7d4b6f550a2311df19 (diff) | |
download | redis-68661171940480ff9bfa55936ceab2ae252340f0.tar.gz |
Fix missing separator in module info line (usedby and using lists) (#9241)
Fix module info genModulesInfoStringRenderModulesList lack separator when there's more than one module in the list.
Co-authored-by: Oran Agra <oran@redislabs.com>
(cherry picked from commit 1895e134a77efd789b1a6daee76a6ba5ec90e516)
-rw-r--r-- | src/module.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/module.c b/src/module.c index c5de4b787..94107362b 100644 --- a/src/module.c +++ b/src/module.c @@ -8701,8 +8701,9 @@ sds genModulesInfoStringRenderModulesList(list *l) { while((ln = listNext(&li))) { RedisModule *module = ln->value; output = sdscat(output,module->name); + if (ln != listLast(l)) + output = sdscat(output,"|"); } - output = sdstrim(output,"|"); output = sdscat(output,"]"); return output; } |