Properly cleanup the size_mail table when removing mails

Closes: #1196
This commit is contained in:
Antoine Beaupré 2009-08-04 18:37:14 +00:00
parent 72a8be3fb5
commit 83efd6f0ad
1 changed files with 1 additions and 0 deletions

View File

@ -579,6 +579,7 @@ class m_mail {
$err->log("mail","_deletepop",$mail."@".$dom);
$db->query("DELETE FROM mail_users WHERE uid='$cuid' AND ( alias='". $mail."_".$dom."' OR alias='". $mail."@".$dom."' ) ;");
$db->query("DELETE FROM mail_alias WHERE mail='".$mail."_".$dom."';");
$db->query("DELETE FROM size_mail WHERE alias='".$mail."_".$dom."';");
@unlink("/var/lib/squirrelmail/data/".$mail."_".$dom.".pref");
@unlink("/var/lib/squirrelmail/data/".$mail."_".$dom.".abook");
@unlink("/var/lib/squirrelmail/data/".$mail."@".$dom.".pref");