From 4f6915b0b73ad58e1e2a578a36f750b309463e87 Mon Sep 17 00:00:00 2001 From: indiri69 Date: Fri, 23 Aug 2002 17:49:01 +0000 Subject: [PATCH] Replaced some deleted lines that are need for filters to work correctly. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@3444 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- plugins/filters/filters.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/plugins/filters/filters.php b/plugins/filters/filters.php index 2f3ac1a5..381c7b97 100644 --- a/plugins/filters/filters.php +++ b/plugins/filters/filters.php @@ -53,7 +53,6 @@ function filters_SaveCache () { fclose($fp); } - function filters_LoadCache () { global $data_dir, $SpamFilters_DNScache; @@ -165,8 +164,8 @@ function filters_bulkquery($filters_spam_scan, $filters, $read) { function start_filters() { global $mailbox, $username, $key, $imapServerAddress, $imapPort, $imap, - $imap_general, $filters, $imap_stream, $imapConnection, - $UseSeparateImapConnection, $AllowSpamFilters; + $imap_general, $filters, $imap_stream, $imapConnection, + $UseSeparateImapConnection, $AllowSpamFilters; # if ($mailbox == 'INBOX') { // Detect if we have already connected to IMAP or not. @@ -200,7 +199,6 @@ function start_filters() { # } } - function user_filters($imap_stream) { global $data_dir, $username; $filters = load_filters(); @@ -233,7 +231,7 @@ function user_filters($imap_stream) { // Clean out the mailbox whether or not auto_expunge is on // That way it looks like it was redirected properly if (count($id)) { - sqimap_mailbox_expunge($imap_stream, 'INBOX'); + sqimap_mailbox_expunge($imap_stream, 'INBOX'); } } @@ -259,6 +257,8 @@ function filter_search_and_delete($imap, $where, $what, $where_to, $user_scan, $ $where = trim($where . ' ' . $what[0]); $what = addslashes(trim($what[1])); } + $search_str .= ' ' . $where . ' {' . strlen($what) . "}\r\n" + . $what . "\r\n"; /* read data back from IMAP */ $read = sqimap_run_command($imap, $search_str, true, $response, $message, $uid_support); @@ -417,7 +417,6 @@ function spam_filters($imap_stream) { } - // Does the loop through each enabled filter for the specified IP address. // IP format: $a.$b.$c.$d function filters_spam_check_site($a, $b, $c, $d, &$filters) { -- 2.25.1