]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-fs: don't append '/' to prefix in posix-fs
authorMartti Rannanjärvi <martti.rannanjarvi@dovecot.fi>
Thu, 28 Apr 2016 07:06:21 +0000 (10:06 +0300)
committerGitLab <gitlab@git.dovecot.net>
Fri, 29 Apr 2016 19:08:30 +0000 (22:08 +0300)
src/lib-fs/fs-posix.c

index ddd9ccb6871195f0771a98a912380b7f4f27f986..b690c27b992ce338af2e9211ac7b0f917d02cb46 100644 (file)
@@ -96,12 +96,8 @@ fs_posix_init(struct fs *_fs, const char *args, const struct fs_settings *set)
                else if (strcmp(arg, "lock=dotlock") == 0)
                        fs->lock_method = FS_POSIX_LOCK_METHOD_DOTLOCK;
                else if (strncmp(arg, "prefix=", 7) == 0) {
-                       unsigned int len = strlen(arg + 7);
                        i_free(fs->path_prefix);
-                       if (len > 0 && arg[7+len-1] != '/')
-                               fs->path_prefix = i_strconcat(arg + 7, "/", NULL);
-                       else
-                               fs->path_prefix = i_strdup(arg + 7);
+                       fs->path_prefix = i_strdup(arg + 7);
                } else if (strcmp(arg, "mode=auto") == 0) {
                        fs->mode_auto = TRUE;
                } else if (strncmp(arg, "mode=", 5) == 0) {