Mercurial > dovecot > original-hg > dovecot-1.2
changeset 8356:125e530609d4 HEAD
dovecot -n/-a: Fixes to printing which filesystem is being used.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Wed, 29 Oct 2008 20:35:17 +0200 |
parents | 3a0101119ae3 |
children | a66bd1e629a2 |
files | src/master/sysinfo-get.c |
diffstat | 1 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/master/sysinfo-get.c Wed Oct 29 20:28:30 2008 +0200 +++ b/src/master/sysinfo-get.c Wed Oct 29 20:35:17 2008 +0200 @@ -1,7 +1,6 @@ /* Copyright (c) 2008 Dovecot authors, see the included COPYING file */ #include "lib.h" -#include "home-expand.h" #include "mountpoint.h" #include "strescape.h" #include "sysinfo-get.h" @@ -91,8 +90,15 @@ path = mail_location; else path = t_strcut(path + 1, ':'); - path = home_expand(path); + if (*path == '~') { + /* we don't know where users' home dirs are */ + return ""; + } + path = t_strcut(path, '%'); + if (strlen(path) <= 1) + return ""; + /* all in all it seems we can support only /<path>/%u style location */ if (mountpoint_get(path, pool_datastack_create(), &mp) < 0) return ""; return mp.type == NULL ? "" : mp.type;