Mercurial > masqmail
comparison src/pop3_in.h @ 10:26e34ae9a3e3
changed indention and line wrapping to a more consistent style
author | meillo@marmaro.de |
---|---|
date | Mon, 27 Oct 2008 16:23:10 +0100 |
parents | 08114f7dcc23 |
children | f186650135c3 |
comparison
equal
deleted
inserted
replaced
9:31cc8a89cb74 | 10:26e34ae9a3e3 |
---|---|
2 * | 2 * |
3 * This program is free software; you can redistribute it and/or modify | 3 * This program is free software; you can redistribute it and/or modify |
4 * it under the terms of the GNU General Public License as published by | 4 * it under the terms of the GNU General Public License as published by |
5 * the Free Software Foundation; either version 2 of the License, or | 5 * the Free Software Foundation; either version 2 of the License, or |
6 * (at your option) any later version. | 6 * (at your option) any later version. |
7 * | 7 * |
8 * This program is distributed in the hope that it will be useful, | 8 * This program is distributed in the hope that it will be useful, |
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
11 * GNU General Public License for more details. | 11 * GNU General Public License for more details. |
12 * | 12 * |
29 #define POP3_FLAG_UIDL_DELE 0x04 | 29 #define POP3_FLAG_UIDL_DELE 0x04 |
30 #define POP3_FLAG_APOP 0x08 | 30 #define POP3_FLAG_APOP 0x08 |
31 | 31 |
32 #define POP3_MAX_CHILDREN 2 | 32 #define POP3_MAX_CHILDREN 2 |
33 | 33 |
34 typedef | 34 typedef enum _pop3_error { |
35 enum _pop3_error{ | 35 pop3_ok = 0, |
36 pop3_ok = 0, | 36 pop3_fail, |
37 pop3_fail, | 37 pop3_eof, |
38 pop3_eof, | 38 pop3_timeout, |
39 pop3_timeout, | 39 pop3_login_failure, |
40 pop3_login_failure, | 40 pop3_syntax |
41 pop3_syntax | |
42 } pop3_error; | 41 } pop3_error; |
43 | 42 |
44 typedef struct pop3_base{ | 43 typedef struct pop3_base { |
45 FILE *in; | 44 FILE *in; |
46 FILE *out; | 45 FILE *out; |
47 gint sock; | 46 gint sock; |
48 gint dup_sock; | 47 gint dup_sock; |
49 | 48 |
50 gchar *remote_host; | 49 gchar *remote_host; |
51 gchar *buffer; | 50 gchar *buffer; |
52 | 51 |
53 gint next_id; | 52 gint next_id; |
54 gint msg_cnt; | 53 gint msg_cnt; |
55 gint uidl_known_cnt; | 54 gint uidl_known_cnt; |
56 gint mbox_size; | 55 gint mbox_size; |
57 | 56 |
58 GList *list_uid_old; | 57 GList *list_uid_old; |
59 GList *drop_list; | 58 GList *drop_list; |
60 | 59 |
61 gchar* timestamp; | 60 gchar *timestamp; |
62 | 61 |
63 guint flags; | 62 guint flags; |
64 | 63 |
65 pop3_error error; | 64 pop3_error error; |
66 } pop3_base; | 65 } pop3_base; |
67 | 66 |
68 typedef struct _msg_info{ | 67 typedef struct _msg_info { |
69 gint number; | 68 gint number; |
70 gint size; | 69 gint size; |
71 gchar *uid; | 70 gchar *uid; |
72 gboolean is_fetched; | 71 gboolean is_fetched; |
73 gboolean is_in_uidl; | 72 gboolean is_in_uidl; |
74 } msg_info; | 73 } msg_info; |
75 | 74 |
76 pop3_base *pop3_in_open(gchar *host, gint port, GList *resolve_list, guint flags); | 75 pop3_base *pop3_in_open(gchar * host, gint port, GList * resolve_list, guint flags); |
77 pop3_base *pop3_in_open_child(gchar *cmd, guint flags); | 76 pop3_base *pop3_in_open_child(gchar * cmd, guint flags); |
78 void pop3_in_close(pop3_base *popb); | 77 void pop3_in_close(pop3_base * popb); |
79 gboolean pop3_get(pop3_base *popb, | 78 gboolean pop3_get(pop3_base * popb, gchar * user, gchar * pass, address * rcpt, address * return_path, gint max_count, gint max_size, gboolean max_size_delete); |
80 gchar *user, gchar *pass, address *rcpt, address *return_path, | 79 gboolean pop3_login(gchar * host, gint port, GList * resolve_list, gchar * user, gchar * pass, guint flags); |
81 gint max_count, gint max_size, gboolean max_size_delete); | |
82 gboolean pop3_login(gchar *host, gint port, GList *resolve_list, | |
83 gchar *user, gchar *pass, guint flags); | |
84 | 80 |
85 | 81 |
86 | 82 |
87 #endif | 83 #endif |