Mercurial > dovecot > core-2.2
changeset 1254:c7bb9cc26e1f HEAD
Don't delete ".." dirs outside our imap root.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Tue, 25 Feb 2003 21:10:45 +0200 |
parents | 39b899338c99 |
children | 58041ce0a24c |
files | src/lib-storage/index/maildir/maildir-list.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-storage/index/maildir/maildir-list.c Tue Feb 25 21:10:03 2003 +0200 +++ b/src/lib-storage/index/maildir/maildir-list.c Tue Feb 25 21:10:45 2003 +0200 @@ -231,8 +231,9 @@ or the process trying to delete it had died. delete it ourself if it's been there longer than - one hour */ - if (st.st_mtime < 3600) + one hour. don't touch it if it's outside our + mail root dir. */ + if (st.st_mtime < 3600 && *ctx->prefix == '\0') (void)unlink_directory(path, TRUE); continue; }