search for: mail_get_stream

Displaying 20 results from an estimated 23 matches for "mail_get_stream".

2007 Oct 08
1
API problem (noob)
...e help: I'm working on a dovecot plugin, and I would like to copy a mail message from the mail store out to a temporary file, less a few headers: static const char *const exclude_headers[] = { "X-DSPAM-Signature" } strcpy(fname, mktemp(fname)); fd = creat(fname, 0600); mail_get_stream(mail, NULL, NULL, &input); output = o_stream_create_fd_file(fd, 0, TRUE); input = i_stream_create_header_filter(input, HEADER_FILTER_EXCLUDE | HEADER_FILTER_NO_CR, exclude_headers, N_ELEMENTS(exclude_headers), null_header_filter_callback, NULL); o_stream_send_istre...
2009 Apr 13
0
How can I skip EOH in headers?
Hello. My callback for get_stream is called from mail_get_stream in mail_storage_copy. Further, mbox_save_init is called and it called mbox_save_get_input_stream. backtrace (A) for my callback: #0 i_stream_header_filter_read (stream=0x8147e00) at istream-header- filter.c:314 #1 0x080cdbaa in parse_header (mstream=0x8147e00) at istream-header- filter.c:...
2007 Nov 15
1
imap process consuming 100% CPU (Dovecot 1.0.3)
...t;istream.c" > > message_get_body_size(input = 0x2004aabc, body = 0x2002827c, has_nuls = (nil)), line 107 in "message-size.c" > > index_mail_init_stream(_mail = 0x200281a8, hdr_size = 0x2ff227a8, body_size = 0x2ff227b8), line 502 in "index-mail.c" > > mbox_mail_get_stream(_mail = 0x200281a8, hdr_size = 0x2ff227a8, body_size = 0x2ff227b8), line 206 in "mbox-mail.c" > > mail_get_stream(mail = 0x200281a8, hdr_size = 0x2ff227a8, body_size = 0x2ff227b8), line 107 in "mail.c" > > imap-fetch-body.fetch_body(ctx = 0x200205e0, mail = 0x200281a...
2009 Dec 29
2
Retrieve Physical Message Filename
Hi,Using Dovecot 1.2.9 with Maildir and Layout=FS.In a plugin, i'm overriding "update_flags":void my_mail_update_flags(struct mail *_mail, enum modify_type modify_type, enum mail_flags flags)For this email which is having its flags updated, I need to retrieve the physical filename of the message.? I see where using:mail_get_special(_mail, MAIL_FETCH_UIDL_FILE_NAME,? &fname);...I
2015 Oct 29
0
Indexer crash when fixing incorrectly named Maildir files
...x64) [0x76dda320] -> /usr/lib/dovecot/libdovecot-storage.so.0(+0x998b0) [0x76f388b0] -> /usr/lib/dovecot/libdovecot-storage.so.0(index_mail_init_stream+0x1c8) [0x76f38df4] -> /usr/lib/dovecot/libdovecot-storage.so.0(+0x5391c) [0x76ef291c] -> /usr/lib/dovecot/libdovecot-storage.so.0(mail_get_stream+0x68) [0x76ec482c] -> /usr/lib/dovecot/libdovecot-storage.so.0(+0x536f4) [0x76ef26f4] -> /usr/lib/dovecot/libdovecot-storage.so.0(mail_get_virtual_size+0x48) [0x76ec4454] -> /usr/lib/dovecot/libdovecot-storage.so.0(index_mail_precache+0x124) [0x76f3a51c] -> /usr/lib/dovecot/lib20_...
2008 Sep 12
1
API Examples?
I need to write a little client to just get the 5 most recent email headers (and \Seen status) from the INBOX of a given user. Are there any API examples anywhere that would speed this process along, or any spots in the source that would give me a jump start? or would it be better to act as an IMAP client? Many Thanks In Advance, Tom -- View this message in context:
2007 Oct 01
1
Reading mail in a plugin
Does anyone know how to read a mail header and body in a plugin, i.e. what API call(s) to use for the read? /L
2005 Mar 29
0
mbox zlib compression plugin
...mbox name ends with ".gz", if so it opens it as read-only using zlib. If the file isn't actually zlib compressed, zlib seems to be able to still access it as a normal file (but it's still read-only). It should be possible to implement it for maildir files as well by hooking into mail_get_stream(). -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part URL: <http://dovecot.org/pipermail/dovecot/attachments/20050329/594595d4/attachment-0001.bin>
2005 Jun 16
1
imap crash
..._match_mail (mbox=0x80c3ba8, view=0x80c8ea8, seq=2028) at mbox-sync-parse.c:521 #2 0x080689d0 in mbox_file_seek (mbox=0x80c3ba8, view=0x80c8ea8, seq=2028, deleted_r=0xbffff748) at mbox-file.c:164 #3 0x0806a91f in mbox_mail_seek (mail=0x80c9200) at mbox-mail.c:63 #4 0x0806ab2a in mbox_mail_get_stream (_mail=0x80c9200, hdr_size=0x0, body_size=0x0) at mbox-mail.c:176 #5 0x0808cc55 in mail_get_stream (mail=0xfffffffe, hdr_size=0x0, body_size=0x0) at mail.c:106 #6 0x080760ef in index_mail_get_header_stream (_mail=0x80c9200, _headers=0x80c95d8) at index-mail-headers.c:606 #7 0x0...
2005 Oct 27
1
dovecot-lda cvs
I am using dovecot-lda from cvs (checked out on september the 21st) and dovecot 1.0alpha2 (not yet upgraded ok). I have a strange feeling about "redirect" feature. Let's see two sieve scripts examples: # ex1 require ["fileinto", "vacation"]; if header :is ["blabla"] "blabla" { fileinto "blabla"; } redirect
2006 Jul 19
0
data corruption in delivery agent when forwarding
...++ mail-send.c 19 Jul 2006 09:28:18 -0000 @@ -116,16 +116,17 @@ struct smtp_client *smtp_client; FILE *f; const unsigned char *data; + const char *return_path; size_t size; int ret; + return_path = mail_get_first_header(mail, "Return-Path"); + input = mail_get_stream(mail, NULL, NULL); if (input == NULL) return -1; - smtp_client = smtp_client_open(forwardto, - mail_get_first_header(mail, "Return-Path"), - &f); + smtp_client = smtp_client_open(forwardto, return_path, &f); input = i_stream_create_header_filt...
2009 Jun 22
1
A X-Mailbox header?
Hi all, I'm waiting for the virtual mailbox feature in order to make a single POP3 access to retrieve messages contained in all my mailbox folders. This is because I use webmail and other IMAP clients but my main workstation uses a POP3-only client. I was wondering if there's a way to keep the name of the folder containing each message while retrieving via POP3. I guess this could
2011 Jan 19
1
Rewrite the mailbox copy functions works in imap but don't work in doveadm import command
Hi Timo !! I rewrite the copy function from mailbox (using a plugin) My rewrite is like this: static int emexis_antispam_copy(struct mail_save_context *ctx, struct mail *mail){ struct mailbox *box = ctx->transaction->box; union mailbox_module_context *zbox = EMEXIS_CONTEXT(box); struct mail_private *_mail = (struct mail_private *)mail; union mail_module_context *zmail =
2014 Aug 20
1
Assertion in istream.c::167 in POP3 mode when maildir content has wrong S value (using 2.2.13)
.../lib64/dovecot/libdovecot.so.0(message_get_body_size+0x9d) [0x7f5065299b3d] -> /usr/lib64/dovecot/libdovecot-storage.so.0(index_mail_init_stream+0x200) [0x7f506556f700] -> /usr/lib64/dovecot/libdovecot-storage.so.0(+0x2dd0f) [0x7f506553cd0f] -> /usr/lib64/dovecot/libdovecot-storage.so.0(mail_get_stream+0x4b) [0x7f506554915b] -> /usr/lib64/dovecot/libdovecot-storage.so.0(+0x2dae7) [0x7f506553cae7] -> dovecot/pop3(client_create+0x56d) [0x40622d] -> dovecot/pop3() [0x404ea3] -> dovecot/pop3() [0x40508f] -> /usr/lib64/dovecot/libdovecot.so.0(+0x28346) [0x7f5065261346] -> /usr/...
2009 Sep 01
2
antispam-plugin 1.2 and trailing carriage-returns
Guys, Dovecot 1.0.15 [1], just built the latest antispam-plugin 1.2 (tarball) for testing, mailtrain backend for SA integration. Both built from custom spec files. The mail that is being trained is different than its respective source in the mbox file. The trained one shows added, trailing carriage-return chars for all headers, which are not in the headers in the mbox file. This breaks sa-learn
2015 Jan 07
0
Cached message size smaller than expected
...libdovecot.so.0(message_get_body_size+0xa9) [0x7feb1445da89] -> /usr/local/lib/dovecot/libdovecot-storage.so.0(index_mail_init_stream+0x16f) [0x7feb1473795f] -> /usr/local/lib/dovecot/libdovecot-storage.so.0(+0x2dacc) [0x7feb14701acc] -> /usr/local/lib/dovecot/libdovecot-storage.so.0(mail_get_stream+0x4d) [0x7feb1470f3ed] -> /usr/local/lib/dovecot/libdovecot-storage.so.0(+0x2e3e8) [0x7feb147023e8] -> /usr/local/lib/dovecot/libdovecot-storage.so.0(mail_get_virtual_size+0x2b) [0x7feb1470f07b] -> dovecot/imap() [0x41b2f5] -> dovecot/imap() [0x419d6c] -> dovecot/imap(imap_fetc...
2011 Jan 17
0
dsync crash
...stream_from (file=0x81ef248, stream=0xbffff10c) at dbox-attachment.c:168 #9 dbox_attachment_file_get_stream (file=0x81ef248, stream=0xbffff10c) at dbox-attachment.c:223 #10 0xb7f96a79 in get_mail_stream (_mail=0x81993a8, hdr_size=0x0, body_size=0x0, stream_r=0xbffff17c) at dbox-mail.c:234 #11 dbox_mail_get_stream (_mail=0x81993a8, hdr_size=0x0, body_size=0x0, stream_r=0xbffff17c) at dbox-mail.c:253 #12 0xb7f3d4f7 in mail_get_stream (mail=0x0, hdr_size=0x0, body_size=0x0, stream_r=0xbffff17c) at mail.c:179 #13 0xb7d1a66a in zlib_mail_save_finish (ctx=0x81d3ee8) at zlib-plugin.c:253 #14 0xb7f43438 in mailbox_...
2009 Oct 03
1
Another 1.2.5 imap panic
We've had another random imap process crash. This is with the original 1.2.5 imap (I haven't applied the patch for two processes creating an index simultaneously): > Oct 03 13:24:56 imap-login: Info: Login: user=<xxxxxxxx>, method=PLAIN, rip=134.225.1.46, lip=134.225.16.6 > Oct 03 13:25:59 IMAP 6067 xxxxxxxx 134.225.1.46 : Info: delete: uid=483, msgid=<xxxxxxxx> > Oct
2008 Jul 23
2
Dovecot 1.1.1 + zlib plugin + mbox crash
...(input->v_offset == 0) dovecot: Jul 23 15:35:54 Error: IMAP 888 xxxxxxxx xxx.xxx.xxx.xxx : Raw backtrace: imap [0x4833b8] -> imap [0x483413] -> imap [0x482e46] -> imap [0x43ce47] -> imap(mbox_file_open_stream+0x40) [0x434f40] -> imap [0x4363c1] -> imap [0x436778] -> imap(mail_get_stream+0xa) [0x4547ea] -> imap(index_mail_set_seq+0x144) [ 0x44b444] -> imap [0x436a79] -> imap(mail_set_seq+0x7) [0x454697] -> imap(index_storage_search_next_nonblock+0xd7) [0x44ef07] -> imap(mailbox_search_next_non block+0x10) [0x455ef0] -> imap(mailbox_search_next+0x20) [0x455f20]...
2007 Sep 29
3
plugin problem
I'm trying to do a rewrite of the dspam_plugin for dovecot 1.1b1. There are some API changes that warranted an update of the plugin. Also, I wanted the dspam_plugin to be able to handle pristine mails for dspam retraining, as opposed to the signature based retraining. Question: How can I retrieve the full unix path for a specific mail? The original code uses mail_get_first_header() to