summaryrefslogtreecommitdiff
path: root/include/mailutils/sys/amd.h
AgeCommit message (Collapse)AuthorFiles
2016-11-29Remove compatibility support for obsolete .mu-sizeSergey Poznyakoff1
2016-01-22Update copyright yearsSergey Poznyakoff1
2015-03-02Update copyright yearsSergey Poznyakoff1
2014-02-05Update copyright years.Sergey Poznyakoff1
2012-01-05Happy GNU YearSergey Poznyakoff1
2011-10-20Change attribute handling in Maildir format.Sergey Poznyakoff1
* include/mailutils/message.h (MU_MSG_ATTRIBUTE_MODIFIED) (MU_MSG_HEADER_MODIFIED,MU_MSG_BODY_MODIFIED): New flags. * libmailutils/mailbox/message.c (mu_message_is_modified): Return a bitmask from the above values. * libmailutils/property/create.c (mu_property_create_init): Return error code. * include/mailutils/sys/amd.h (_amd_data) <chattr_msg> <capabilities, prop>: New members. <uidvalidity>: Remove. * libmailutils/base/amd.c: Use MH-style proplist to keep the mailbox properties: uidvalidity, last uid and to cache its size. Store message attributes in the message header only if the mailbox implementation is unable to keep them elsewhere. Use chattr_msg method (if provided) to flush changes in message attributes. * libproto/maildir/folder.c (_maildir_list_p): Ignore .mh* and .mu* files. * libproto/mh/folder.c (_mh_list_p): Likewise. * libproto/maildir/mbox.c: Implement all Maildir flags (except P). Implement the chattr_msg method. * libproto/mh/mbox.c: Remove special handling for uidvalidity. * mh/tests/folder.at: Ignore .mu-prop in directory listings.
2011-01-02Update copyright years.Sergey Poznyakoff1
Happy GNU year!
2010-12-28mh,maildir: speed up scanning.Sergey Poznyakoff1
* include/mailutils/sys/amd.h (_amd_message_append, amd_sort): New protos. * libmailutils/base/amd.c (amd_array_expand): Call memmove only if there is actually something to move. (_amd_message_append, amd_sort): New functions. * libproto/maildir/mbox.c (maildir_scan_dir): Append new messages to the end of the array, and sort it afterwards. This avoids unnecessary memory moves, which improves performance considerably, especially on large mailboxes. * libproto/mh/mbox.c (mh_scan0): Likewise.
2010-12-19maildir: speed up mailbox scanningSergey Poznyakoff1
* include/mailutils/sys/amd.h (_amd_message_lookup_or_insert): New proto. * libmailutils/base/amd.c (_amd_message_lookup_or_insert): New function. (_amd_message_insert): Rewrite using _amd_message_lookup_or_insert. * libproto/maildir/mbox.c (maildir_message_cmp): Stop comparison on ':'. (maildir_message_lookup): Remove. (maildir_scan_dir): Use _amd_message_lookup_or_insert. * po/POTFILES.in: Update.
2010-11-24mh: implement rmmproc.Sergey Poznyakoff1
* include/mailutils/sys/amd.h (_amd_data) <delete_msg>: New method. * libmailutils/base/amd.c (amd_expunge): If delete_msg is defined, use it. * libproto/mh/mbox.c (_mh_msg_delete): New method. (_mailbox_mh_init): Set delete_msg if "rmmproc" component is defined. * mh/tests/movemsg: New file. * mh/tests/Makefile.am (EXTRA_DIST): Add movemsg. * mh/tests/rmm.at: Test rmmproc effects. * mh/tests/rmf.at (MH_KEYWORDS): Fix copy-n-paste error. * doc/texinfo/mu-mh.texi: Document rmmproc. * mh/TODO: Update.
2010-10-09Fix copyleft notices to follow the GNU standards.Sergey Poznyakoff1
2010-09-16Implement `remove' method for mailboxes.Sergey Poznyakoff1
* include/mailutils/mailbox.h (mu_mailbox_remove): New function. * include/mailutils/stream.h: Add some comments. * include/mailutils/sys/amd.h (_amd_data)<remove>: New method. (amd_remove_dir): New function. * include/mailutils/sys/mailbox.h (_mu_mailbox)<_remove>: New method. * libmailutils/amd.c (amd_remove_mbox): New function. (amd_init_mailbox): Initialize the _remove method. (amd_remove_dir): New function. * libmailutils/errors (MU_ERR_MBX_REMOVED) (MU_ERR_NOT_OPEN, MU_ERR_OPEN): New error codes. * libmailutils/mailbox.c: Keep state of the mailbox (open vs. not open, removed). Check it before doing anything on it. (_MU_MAILBOX_OPEN, _MU_MAILBOX_REMOVED, _MU_MAILBOX_MASK): New defines. (mu_mailbox_open): Set _MU_MAILBOX_OPEN if the operation succeeds. (mu_mailbox_close): Clear _MU_MAILBOX_OPEN if the operation succeeds. Refuse to run if the mailbox was not opened. (mu_mailbox_remove): New function. (all functions): return MU_ERR_MBX_NULL if the mbox argument is NULL. Check mailbox state on entry and proceed accordingly. * libproto/maildir/mbox.c: Implement _remove method. (maildir_remove): New function. (_mailbox_maildir_init): Initialize amd->_remove. * libproto/mbox/mbox.c: Implement _remove method. (mbox_remove): New function. (_mailbox_mbox_init): Initialize amd->_remove. * libproto/mh/mbox.c: Implement _remove method. (mh_remove): New function. (_mailbox_mh_init): Initialize amd->_remove. * libmailutils/tests/mbdel.c: New file. * libmailutils/tests/.gitignore: Add mbdel. * libmailutils/tests/Makefile.am (noinst_PROGRAMS): Likewise. (LDADD): List all mailbox formats. * imap4d/delete.c (imap4d_delete): Use mu_mailbox_remove to delete the folder. Fall back to remove() if it does not appear to be a mailbox.
2010-09-08Reorganize directory tree.Sergey Poznyakoff1
Move libproto/include/(*)0.h to include/mailutils/sys/\1.h Remove libproto/include.

Return to:

Send suggestions and report system problems to the System administrator.