1 diff -ur dovecot-1.0.rc15-o/src/master/mail-process.c dovecot-1.0.rc15/src/master/mail-process.c
2 --- dovecot-1.0.rc15-o/src/master/mail-process.c 2006-10-17 04:50:31.000000000 -0600
3 +++ dovecot-1.0.rc15/src/master/mail-process.c 2007-01-31 22:42:50.000000000 -0700
5 env_put("POP3_NO_FLAG_UPDATES=1");
6 if (set->pop3_reuse_xuidl)
7 env_put("POP3_REUSE_XUIDL=1");
8 + if (set->pop3_ignore_deleted)
9 + env_put("POP3_IGNORE_DELETED=1");
10 if (set->pop3_enable_last)
11 env_put("POP3_ENABLE_LAST=1");
12 if (set->pop3_lock_session)
13 diff -ur dovecot-1.0.rc15-o/src/master/master-settings.c dovecot-1.0.rc15/src/master/master-settings.c
14 --- dovecot-1.0.rc15-o/src/master/master-settings.c 2006-11-12 10:56:07.000000000 -0700
15 +++ dovecot-1.0.rc15/src/master/master-settings.c 2007-01-31 22:42:50.000000000 -0700
17 DEF(SET_BOOL, pop3_enable_last),
18 DEF(SET_BOOL, pop3_reuse_xuidl),
19 DEF(SET_BOOL, pop3_lock_session),
20 + DEF(SET_BOOL, pop3_ignore_deleted),
21 DEF(SET_STR, pop3_uidl_format),
22 DEF(SET_STR, pop3_client_workarounds),
23 DEF(SET_STR, pop3_logout_format),
25 MEMBER(pop3_enable_last) FALSE,
26 MEMBER(pop3_reuse_xuidl) FALSE,
27 MEMBER(pop3_lock_session) FALSE,
28 + MEMBER(pop3_ignore_deleted) FALSE,
29 MEMBER(pop3_uidl_format) "",
30 MEMBER(pop3_client_workarounds) "",
31 MEMBER(pop3_logout_format) "top=%t/%p, retr=%r/%b, del=%d/%m, size=%s",
32 diff -ur dovecot-1.0.rc15-o/src/master/master-settings.h dovecot-1.0.rc15/src/master/master-settings.h
33 --- dovecot-1.0.rc15-o/src/master/master-settings.h 2006-10-17 04:48:45.000000000 -0600
34 +++ dovecot-1.0.rc15/src/master/master-settings.h 2007-01-31 22:42:50.000000000 -0700
36 bool pop3_enable_last;
37 bool pop3_reuse_xuidl;
38 bool pop3_lock_session;
39 + bool pop3_ignore_deleted;
40 const char *pop3_uidl_format;
41 const char *pop3_client_workarounds;
42 const char *pop3_logout_format;
43 diff -ur dovecot-1.0.rc15-o/src/pop3/client.c dovecot-1.0.rc15/src/pop3/client.c
44 --- dovecot-1.0.rc15-o/src/pop3/client.c 2006-08-10 16:26:41.000000000 -0600
45 +++ dovecot-1.0.rc15/src/pop3/client.c 2007-01-31 22:42:50.000000000 -0700
47 message_sizes_buf = buffer_create_dynamic(default_pool, 512);
49 memset(&search_arg, 0, sizeof(search_arg));
50 - search_arg.type = SEARCH_ALL;
51 + if(ignore_deleted_messages) {
52 + search_arg.type = SEARCH_DELETED;
55 + search_arg.type = SEARCH_ALL;
58 for (i = 0; i < 2; i++) {
59 if (sync_mailbox(client->mailbox, &status) < 0) {
60 diff -ur dovecot-1.0.rc15-o/src/pop3/common.h dovecot-1.0.rc15/src/pop3/common.h
61 --- dovecot-1.0.rc15-o/src/pop3/common.h 2006-04-27 06:29:14.000000000 -0600
62 +++ dovecot-1.0.rc15/src/pop3/common.h 2007-01-31 22:55:11.000000000 -0700
65 extern struct ioloop *ioloop;
66 extern enum client_workarounds client_workarounds;
67 -extern bool enable_last_command, no_flag_updates, reuse_xuidl, lock_session;
68 +extern bool enable_last_command, no_flag_updates, reuse_xuidl, lock_session, ignore_deleted_messages;
69 extern const char *uidl_format, *logout_format;
70 extern enum uidl_keys uidl_keymask;
72 diff -ur dovecot-1.0.rc15-o/src/pop3/main.c dovecot-1.0.rc15/src/pop3/main.c
73 --- dovecot-1.0.rc15-o/src/pop3/main.c 2006-08-10 12:38:04.000000000 -0600
74 +++ dovecot-1.0.rc15/src/pop3/main.c 2007-01-31 22:42:50.000000000 -0700
76 bool no_flag_updates = FALSE;
77 bool reuse_xuidl = FALSE;
78 bool lock_session = FALSE;
79 +bool ignore_deleted_messages = FALSE;
80 const char *uidl_format, *logout_format;
81 enum uidl_keys uidl_keymask;
84 no_flag_updates = getenv("POP3_NO_FLAG_UPDATES") != NULL;
85 reuse_xuidl = getenv("POP3_REUSE_XUIDL") != NULL;
86 lock_session = getenv("POP3_LOCK_SESSION") != NULL;
87 + ignore_deleted_messages = getenv("POP3_IGNORE_DELETED") != NULL;
89 uidl_format = getenv("POP3_UIDL_FORMAT");
90 if (uidl_format == NULL || *uidl_format == '\0')