diff options
-rw-r--r-- | Src/utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Src/utils.c b/Src/utils.c index 6671c62d9..5e9fbfb82 100644 --- a/Src/utils.c +++ b/Src/utils.c @@ -1793,7 +1793,7 @@ zjoin(char **arr, int delim, int heap) for (s = arr; *s; s++) len += strlen(*s) + 1; if (!len) - return ""; + return heap? "" : ztrdup(""); ptr = ret = (heap ? (char *) hcalloc(len) : (char *) zcalloc(len)); for (s = arr; *s; s++) { strucpy(&ptr, *s); |