Mercurial > dovecot > original-hg > dovecot-1.2
annotate src/imap/common.h @ 6410:e4eb71ae8e96 HEAD
Changed .h ifdef/defines to use <NAME>_H format.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Sun, 16 Sep 2007 11:31:27 +0300 |
parents | 23c9ac999578 |
children | 284dd5f2777d |
rev | line source |
---|---|
6410
e4eb71ae8e96
Changed .h ifdef/defines to use <NAME>_H format.
Timo Sirainen <tss@iki.fi>
parents:
6353
diff
changeset
|
1 #ifndef COMMON_H |
e4eb71ae8e96
Changed .h ifdef/defines to use <NAME>_H format.
Timo Sirainen <tss@iki.fi>
parents:
6353
diff
changeset
|
2 #define COMMON_H |
0 | 3 |
4 #include "lib.h" | |
5 #include "client.h" | |
6 | |
1212 | 7 /* Disconnect client after idling this many seconds */ |
8 #define CLIENT_IDLE_TIMEOUT (60*30) | |
9 | |
2421
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
10 /* If we can't send anything to client for this long, disconnect the client */ |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
11 #define CLIENT_OUTPUT_TIMEOUT (5*60) |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
12 |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
13 /* Stop buffering more data into output stream after this many bytes */ |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
14 #define CLIENT_OUTPUT_OPTIMAL_SIZE 2048 |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
15 |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
16 /* Disconnect client when it sends too many bad commands in a row */ |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
17 #define CLIENT_MAX_BAD_COMMANDS 20 |
d141e1bfdd63
We never do blocking reads/writes to network anymore. Changed imap and pop3
Timo Sirainen <tss@iki.fi>
parents:
2316
diff
changeset
|
18 |
1591
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
19 /* RFC-2683 recommends at least 8000 bytes. Some clients however don't |
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
20 break large message sets to multiple commands, so we're pretty liberal |
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
21 by default. */ |
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
22 #define DEFAULT_IMAP_MAX_LINE_LENGTH 65536 |
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
23 |
2316
1c1ed4494aa4
Split client_workarounds to imap_ and pop3_ ones. Added outlook-no-nuls POP3
Timo Sirainen <tss@iki.fi>
parents:
1958
diff
changeset
|
24 enum client_workarounds { |
3204
c8fffa286b6a
Renamed oe6-fetch-no-newmail workaround to delay-newmail and changed it to
Timo Sirainen <tss@iki.fi>
parents:
2792
diff
changeset
|
25 WORKAROUND_DELAY_NEWMAIL = 0x01, |
3505
0e05687892dc
Added tb-extra-mailbox-sep IMAP workaround.
Timo Sirainen <tss@iki.fi>
parents:
3259
diff
changeset
|
26 WORKAROUND_NETSCAPE_EOH = 0x04, |
0e05687892dc
Added tb-extra-mailbox-sep IMAP workaround.
Timo Sirainen <tss@iki.fi>
parents:
3259
diff
changeset
|
27 WORKAROUND_TB_EXTRA_MAILBOX_SEP = 0x08 |
2316
1c1ed4494aa4
Split client_workarounds to imap_ and pop3_ ones. Added outlook-no-nuls POP3
Timo Sirainen <tss@iki.fi>
parents:
1958
diff
changeset
|
28 }; |
1c1ed4494aa4
Split client_workarounds to imap_ and pop3_ ones. Added outlook-no-nuls POP3
Timo Sirainen <tss@iki.fi>
parents:
1958
diff
changeset
|
29 |
903
fd8888f6f037
Naming style changes, finally got tired of most of the typedefs. Also the
Timo Sirainen <tss@iki.fi>
parents:
0
diff
changeset
|
30 extern struct ioloop *ioloop; |
1591
6eca99b727a0
IMAP parser memory limits are now enforced by bytes per line rather than
Timo Sirainen <tss@iki.fi>
parents:
1586
diff
changeset
|
31 extern unsigned int imap_max_line_length; |
2316
1c1ed4494aa4
Split client_workarounds to imap_ and pop3_ ones. Added outlook-no-nuls POP3
Timo Sirainen <tss@iki.fi>
parents:
1958
diff
changeset
|
32 extern enum client_workarounds client_workarounds; |
5980
57b70f64f997
Added imap_logout_format setting with default to bytes=%i/%o
Timo Sirainen <tss@iki.fi>
parents:
4848
diff
changeset
|
33 extern const char *logout_format; |
0 | 34 |
1586
898a95426118
Keep capability in string_t so plugins can modify it.
Timo Sirainen <tss@iki.fi>
parents:
1212
diff
changeset
|
35 extern string_t *capability_string; |
898a95426118
Keep capability in string_t so plugins can modify it.
Timo Sirainen <tss@iki.fi>
parents:
1212
diff
changeset
|
36 |
1643 | 37 extern void (*hook_client_created)(struct client **client); |
1641
6498f3cb9d2c
Added hook_client_created and hook_mail_storage_created for modules.
Timo Sirainen <tss@iki.fi>
parents:
1622
diff
changeset
|
38 |
0 | 39 #endif |