aboutsummaryrefslogtreecommitdiffstats
path: root/camel/providers/local
Commit message (Collapse)AuthorAgeFilesLines
* override CAMEL_FOLDER_NAME arg so we can translate "." into "Inbox".Not Zed2004-06-282-2/+33
| | | | | | | | | | 2004-06-28 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-folder.c (maildir_folder_getv): override CAMEL_FOLDER_NAME arg so we can translate "." into "Inbox". svn path=/trunk/; revision=26538
* take url argument directly, fixes a memleak. (camel_folder_info_new): makeNot Zed2004-06-281-7/+22
| | | | | | | | | | | | 2004-06-28 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (camel_folder_info_new): take url argument directly, fixes a memleak. (camel_folder_info_new): make the toplevel "." into "Inbox" always. (maildir_rename_folder): dont let users rename inbox. svn path=/trunk/; revision=26537
* If we fail to lock the folder, close the lockfd and reset it to -1. FixesJeffrey Stedfast2004-06-251-1/+4
| | | | | | | | | | 2004-06-24 Jeffrey Stedfast <fejj@novell.com> * providers/local/camel-spool-folder.c (spool_lock): If we fail to lock the folder, close the lockfd and reset it to -1. Fixes bug #54680. svn path=/trunk/; revision=26499
* if we scan from "" or top == NULL, then we really want to scan from "."Not Zed2004-06-111-1/+1
| | | | | | | | | | | | | | | 2004-06-11 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (get_folder_info): if we scan from "" or top == NULL, then we really want to scan from "." instead. * camel-url.c (camel_url_new_with_base): don't check the for a character after the # before extracting the fragment. An empty fragment is still allowed and # should never be added to the path. See Rfc1808 2.4.1. svn path=/trunk/; revision=26304
* removed.Not Zed2004-05-266-11/+0
| | | | | | | | | | | | 2004-05-25 Not Zed <NotZed@Ximian.com> * camel-store.c (camel_folder_info_build_path): removed. * camel-store.h (CamelFolderInfo): removed 'path', fixed all callers. (struct _CamelStore): removed 'dir_sep' fixed all uses. svn path=/trunk/; revision=26089
* re-arrange the code so exception debug will print the expandedNot Zed2004-05-213-19/+24
| | | | | | | | | | | | | | | | | | 2004-05-20 Not Zed <NotZed@Ximian.com> * camel-exception.c (camel_exception_setv): re-arrange the code so exception debug will print the expanded description. (camel_exception_set): print exception debug. * providers/pop3/camel-pop3-folder.c (pop3_get_message): same. * providers/local/camel-mh-folder.c (mh_get_message) * providers/local/camel-mbox-folder.c (mbox_get_message): * providers/local/camel-maildir-folder.c (maildir_get_message): Don't use INVALID_UID for errors which are more system related. And sync up all the error messages. svn path=/trunk/; revision=26028
* do the same load of mailbox if we're in slow mode as we did for maildir.Not Zed2004-05-181-0/+5
| | | | | | | | | | 2004-05-18 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (fill_fi): do the same load of mailbox if we're in slow mode as we did for maildir. #58294. svn path=/trunk/; revision=25948
* ** Bug #56050.Not Zed2004-05-171-3/+41
| | | | | | | | | | | | | | | 2004-05-17 Not Zed <NotZed@Ximian.com> ** Bug #56050. * providers/imap/camel-imap-store.c (imap_get_trash) (imap_get_junk): similar to below. * providers/local/camel-local-store.c (local_get_trash) (local_get_junk): set state file on trash/junk to something we know about. svn path=/trunk/; revision=25918
* if we have no folder in-memory, load it if we're not doing it fast to getNot Zed2004-05-171-0/+5
| | | | | | | | | | 2004-05-17 Not Zed <NotZed@Ximian.com> * providers/local/camel-mh-store.c (fill_fi): if we have no folder in-memory, load it if we're not doing it fast to get really up to date unread counts. #57616. svn path=/trunk/; revision=25917
* changed to match_threads. (camel_folder_search_search): remove threadNot Zed2004-05-121-33/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-05-12 Not Zed <NotZed@Ximian.com> * camel-folder-search.c (search_threads): changed to match_threads. (camel_folder_search_search): remove thread matching stuff from here. 2004-05-06 Not Zed <NotZed@Ximian.com> * camel-digest-folder.c (digest_search_by_expression) (digest_search_by_uids): * providers/nntp/camel-nntp-folder.c (nntp_folder_search_by_expression) (nntp_folder_search_by_uids): * providers/imap/camel-imap-folder.c (imap_search_by_expression) (imap_search_by_uids): * providers/local/camel-local-folder.c (local_search_by_expression) (local_search_by_uids): use camel_folder_search_search & some minor cleanups. * camel-folder-search.c (search_threads): keep track of the match threads option for this search. (camel_folder_search_match_expression): Removed, not used anymore. (camel_folder_search_search): new api entry point for searching, a bit easier to use and needed for thread matching. * camel-folder-search.c (camel_folder_search_search): new search api entry point, take a full summary and optionally a subset of uids to match against. (search_match_all): use the uids' passed in to only search a subset of uid's. svn path=/trunk/; revision=25876
* ** See #57979.Not Zed2004-05-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | 2004-05-04 Not Zed <NotZed@Ximian.com> ** See #57979. * camel-vee-folder.c (subfolder_renamed_update): when the subfolder gets renamed, remove all the old uid's and add the new ones (since the uid is based on the subordinate folder name). (subfolder_renamed): listen to renamed folder events. * providers/local/camel-mbox-store.c (get_folder_info): if we're getting a single folder with no children, make sure we fill the counts out. Fixes some rename strangeness. * camel-vee-folder.c (camel_vee_folder_add_folder): hook onto the folder renamed signal. (camel_vee_folder_finalise): unhook folder_renamed signal. (camel_vee_folder_remove_folder): same. svn path=/trunk/; revision=25776
* include camel-debug.hNot Zed2004-04-081-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-04-08 Not Zed <NotZed@Ximian.com> * camel-folder.c: include camel-debug.h * providers/local/camel-mbox-folder.c (mbox_set_message_user_flag): message changed to folder_changed. (mbox_set_message_user_tag): ditto. * camel-vee-folder.c (camel_vee_folder_finalise): dont hook onto message_changed. (camel_vee_folder_add_folder): or unhook. (camel_vee_folder_remove_folder): " (message_changed): or proxy. * camel-folder.c (camel_folder_class_init): removed the message_changed event - its redundant, and covered by folder_changed, and just makes life difficult for everything using message_changed/folder_changed (and nothing uses it anyway). (message_changed): removed. (set_message_user_flag): emit a folder_changed event instead of message changed. (set_message_user_tag): " (set_message_flags): " * camel-object.h: revered the CAMEL_OBJECT_TYPE change, it should be a global variable access. svn path=/trunk/; revision=25367
* Removed debugging printfs.Jeffrey Stedfast2004-03-302-4/+1
| | | | | | | | | | | | | | | | 2004-03-29 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (get_folder_info): Removed debugging printfs. * providers/local/camel-local-folder.c (camel_local_folder_construct): Since the folder was *just* created, it shouldn't have any subfolders so set the CAMEL_FOLDER_NOCHILDREN flag (altho, ideally, we wouldn't be guessing these flags at all - rather we'd call get_folder_info() or some such). Fixes bug #56010. svn path=/trunk/; revision=25231
* Added new maildir flags D for draft and commented P for forwarded.Not Zed2004-03-261-0/+2
| | | | | | | | | | | | | | 2004-03-26 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-summary.c (flagbits[]): Added new maildir flags D for draft and commented P for forwarded. * providers/imap/camel-imap-store.c (get_folder_counts): Instead of looking up the folder in the object bag which will handle reservations and perhaps deadlock, just get the list of opened folders and use them if they're available. Should fix #56045. svn path=/trunk/; revision=25195
* Reverted jeff's fix for #55018, since it wasn't tested, and doesn't work.Not Zed2004-03-171-75/+29
| | | | | | | | | | | | 2004-03-17 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-store.c: Reverted jeff's fix for #55018, since it wasn't tested, and doesn't work. Wrote an alternate implementation, and tested it at least once. Turns out it was a one line error, it still wasn't tested. Oh well, its rewritten now. svn path=/trunk/; revision=25100
* same as below for path.Not Zed2004-03-152-2/+4
| | | | | | | | | | | | | | | | | | 2004-03-15 Not Zed <NotZed@Ximian.com> * providers/local/camel-mbox-store.c (delete_folder): same as below for path. * providers/local/camel-local-store.c (delete_folder): NULL out str before looking up the state file using it. Otherwise we double-free str. * camel-mime-parser.c (folder_scan_skip_line): we want to scan till in-end-1. If we've been called we're either at the end of data, or we know we have an end of line character within memory. Another case in Bug #53355. svn path=/trunk/; revision=25068
* Fixes for bug #55018.Jeffrey Stedfast2004-03-134-59/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-03-12 Jeffrey Stedfast <fejj@ximian.com> Fixes for bug #55018. * providers/local/camel-local-folder.c (camel_local_folder_construct): Use camel_url_to_string() here too, so we properly encode the fragment. * providers/local/camel-mbox-store.c (get_folder_info): Use CamelURL to properly encode the fi->uri. Pass the CamelURL into scan_dir() so that scan_dir() can re-use it (rather than having to malloc/parse/free for each file/dir) (scan_dir): Use camel_url_to_string(). * providers/local/camel-maildir-store.c (get_folder_info): Same as mbox. (scan_dir): Same as mbox. We also need to set the CAMEL_FOLDER_NOSELECT flag if appropriate. * providers/local/camel-mh-store.c (get_folder_info): Same as mbox and maildir. (folders_scan): Now takes a url argument which we pass off to folder_info_new(). (recursive_scan): Same. (folder_info_new): Use camel_url_to_string(). svn path=/trunk/; revision=25050
* turn off NOINFERIORS always, translate to nochildren.Not Zed2004-03-116-74/+111
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-03-11 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-store.c (get_one_folder_offline): (parse_list_response_as_folder_info): turn off NOINFERIORS always, translate to nochildren. 2004-03-08 Not Zed <NotZed@Ximian.com> * camel-vee-store.c (vee_get_folder_info): setup virtual/system flags as appropriate. (change_folder): setup flags properly. * providers/nntp/camel-nntp-store.c (nntp_store_get_subscribed_folder_info): mark all folders as system folders. * providers/local/camel-mh-store.c (fill_fi): add this to setup folderinfo. (folder_info_new): call fill_fi to fill unread/total. (recursive_scan, folders_scan): ahh yeah, so wtf was i thinking, store->flags != get_folder_info flags!!!! * providers/local/camel-maildir-store.c (camel_folder_info_new): remove unread count arg & setup total. (fill_fi): setup total field. (scan_dir): remove the code that checked the directory directly - use fill_fi instead. It will more accurately reflect what you get when you visit the folder. (camel_folder_info_new): mark "." as a system folder. (scan_dir): try to setup children/no children flags properly. * providers/local/camel-mbox-store.c (fill_fi): setup total field. (scan_dir): init total. (get_folder_info): " 2004-03-05 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-store.c (parse_list_response_as_folder_info): mark INBOX as a system folder. Can't be renamed/deleted. (fill_fi): setup total field. (get_folder_counts): ditto. * camel-store.c (add_special_info): set the system folder flag. * camel-store.h: time to fix up the camelfolderinfo mess. fix some member names, and add some type fields. Fixed all uses. svn path=/trunk/; revision=25019
* Overrides the parent method. We don't want to encode user flags/tags orJeffrey Stedfast2004-03-031-1/+22
| | | | | | | | | | | 2004-03-02 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-summary.c (mbox_summary_encode_x_evolution): Overrides the parent method. We don't want to encode user flags/tags or the size of the header will change and force a complete rewrite of the mbox file. svn path=/trunk/; revision=24937
* If our folder has a subdir, but no actual children, then we need to unsetRodney Dawes2004-02-241-0/+2
| | | | | | | | | | | | 2004-02-23 Rodney Dawes <dobey@ximian.com> * providers/local/camel-mbox-store.c (scan_dir): If our folder has a subdir, but no actual children, then we need to unset the flag for CAMEL_FOLDER_CHILDREN Fixes #54470 svn path=/trunk/; revision=24845
* kill some debugMichael Zucci2004-02-242-16/+3
| | | | svn path=/trunk/; revision=24842
* Add sanity checking to the folder name if we are going to create it, justJeffrey Stedfast2004-02-201-0/+14
| | | | | | | | | | 2004-02-19 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (get_folder): Add sanity checking to the folder name if we are going to create it, just like we do in create_folder(). svn path=/trunk/; revision=24796
* Fixes for api changes.Not Zed2004-02-191-6/+6
| | | | | | | | | | | | | | | | | | | 2004-02-19 Not Zed <NotZed@Ximian.com> * providers/*/camel-*-provider.c (camel_provider_module_init): Fixes for api changes. * camel-provider.c (camel_provider_load): no longer take session argument. the providers are global resources. (camel_provider_init): dont return anything anymore. (error?) call from camel_init now. Use a recursive lock too. * camel-session.c (camel_session_register_provider) (camel_session_list_providers, camel_session_get_provider): Moved to camel-provider, camel_provider_register/list/get. (vee_provider): moved to camel-provider.c svn path=/trunk/; revision=24794
* ** See bug #51045.Not Zed2004-02-166-38/+154
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-02-16 Not Zed <NotZed@Ximian.com> ** See bug #51045. * providers/imap/camel-imap-store.c (fill_fi): similar to mbox version. (get_folder_counts): use fill_fi to try and get folder counts if we're not doing the hard slog. (get_one_folder_offline): use fill_fi to try to get folder counts from open folders or summaries. * providers/local/camel-maildir-store.c (fill_fi): similar to mbox version. (scan_dir): use fill_fi to get the unread count now. * providers/local/camel-mbox-store.c (fill_fi): helper to lookup unread count either from active folder or from summary file, if it's available. (scan_dir, get_folder_info): use helper above to get folder info. * devel-docs/camel-folder-summary.txt: New document describing the format/conventions in the CamelFolderSummary file. * providers/nntp/camel-nntp-summary.c (summary_header_load/save): * providers/imapp/camel-imapp-summary.c (summary_header_load/save): * providers/imap/camel-imap-summary.c (summary_header_load/save): Handle versions, per-class version number (1). * providers/local/camel-mbox-summary.c (summary_header_load/save): Handle versions properly, add a per-class version (1). Write out the folder size as a size_t rather than 32 bit int. * providers/local/camel-local-summary.c (summary_header_load/save): read/write the per-class version number (1). * camel-folder-summary.c (summary_header_load): do version checking differently, allow the version to be bumped without aborting the load. Added unread/deleted/junk counts to base header. (summary_header_save): Save out the new-format header. Version bumped to 13. * camel.c (camel_init): return 0 rather than spit a compiler warning. * camel-file-utils.c (camel_file_util_encode_*_t): macro-ise the type encoder/decoders. Also add size_t encoder/decoder. svn path=/trunk/; revision=24744
* Same.Jeffrey Stedfast2004-02-144-45/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-02-13 Jeffrey Stedfast <fejj@ximian.com> * providers/imap/camel-imap-store.c (get_folder_online): Same. * providers/local/camel-mh-store.c (get_folder): Same as maildir changes. * providers/local/camel-maildir-store.c (get_folder): Make exceptions strings consistanmt with the mbox exception strings (and vise versa). Also handle the CAMEL_STORE_FOLDER_EXCL flag. * providers/local/camel-mbox-store.c (get_folder): Check CAMEL_STORE_FOLDER_EXCL flag. * providers/local/camel-local-store.c (get_folder): Simplified by using camel_mkdir instead of doing it manually. * camel-store.c (camel_store_get_folder): If the folder exists in the cache and the O_EXCL flag was passed, return NULL and set an exception. * camel-store.h: Added a new CAMEL_STORE_FOLDER_EXCL flag for use with get_folder(). svn path=/trunk/; revision=24738
* ** See bug #53978.Not Zed2004-02-091-1/+5
| | | | | | | | | | | | 2004-02-09 Not Zed <NotZed@Ximian.com> ** See bug #53978. * providers/local/camel-mbox-store.c: added ".lock" to the list of ignored extensions. (ignore_file): ignore anything ending in ~ too. svn path=/trunk/; revision=24678
* ** See bug #51319.Not Zed2004-02-091-9/+9
| | | | | | | | | | | | 2004-02-09 Not Zed <NotZed@Ximian.com> ** See bug #51319. * providers/local/camel-local-folder.c (camel_local_folder_construct): re-enable indexing when folder is first opened. Also load defaults if no meta-data present. svn path=/trunk/; revision=24677
* changed to return a boolean to indicate if the flags were actually changedNot Zed2004-02-061-3/+3
| | | | | | | | | | 2004-02-06 Not Zed <NotZed@Ximian.com> * camel-folder.c (camel_folder_set_message_flags): changed to return a boolean to indicate if the flags were actually changed or not. Fixed all implementors. svn path=/trunk/; revision=24643
* rename .cmeta file too, and fix the recovery order.Not Zed2004-02-054-315/+327
| | | | | | | | | | | | | | | | | | 2004-02-05 Not Zed <NotZed@Ximian.com> * providers/local/camel-mbox-store.c (rename_folder): rename .cmeta file too, and fix the recovery order. * providers/local/camel-local-store.c (rename_folder): rename the .cmeta file too. * providers/local/camel-local-folder.c (local_rename): fix this to use local_get_full_path stuff. * camel-store.c (camel_store_rename_folder): fix umr's comparing old and new names. svn path=/trunk/; revision=24630
* ** See bug #53553.Not Zed2004-02-052-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-02-05 Not Zed <NotZed@Ximian.com> ** See bug #53553. * camel-provider.c (camel_provider_init): changed to return a hashtable of url protocols to CamelProviderModule structs, rather than simple strings. * camel-session.c (get_provider): if we load a provider module, mark it as loaded. (ensure_loaded): Check the module loaded flag before trying to load it. * providers/local/libcamellocal.urls: Remove spoold from the list, since it doesn't exist anymore. Actually fixes #53553, the rest is to robustify the code. 2004-02-05 Not Zed <NotZed@Ximian.com> * camel-session.c (CS_CLASS): dont typecheck cast. * camel-store.c (camel_vjunk_folder_new): removed, use vtrash_new(junk). (setup_special): changed to get_special, with a type now, and dont add vtrash folders to the sources. (get_trash, get_junk): down to 1 liners, call get_special * camel-vtrash-folder.c (CF_CLASS): dont use cast typecheck macros here, makes debugging easier and removes redundant checks. (camel_vtrash_folder_init): dont set flags here. (camel_vtrash_folder_new): takes a new argument, type, for junk folders too, removed name arg (taken from type). (vtrash_transfer_messages_to): parameterise flag processing. svn path=/trunk/; revision=24625
* Fix for bug #53755 (local folders case)Jeffrey Stedfast2004-02-051-13/+16
| | | | | | | | | | | | | | | 2004-02-04 Jeffrey Stedfast <fejj@ximian.com> Fix for bug #53755 (local folders case) * providers/local/camel-mbox-store.c (xrename): No longer takes an exception arg, we just set errno. Our caller can take care of setting an exception. (rename_folder): Don't pass an exception to xrename(), we always overwrote if an error occured it anyway. (rename_folder): Rename the .sbd as well. svn path=/trunk/; revision=24616
* Make sure the new dir path exists before trying to rename files to avoidJeffrey Stedfast2004-01-291-7/+39
| | | | | | | | | | | | | 2004-01-28 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (rename_folder): Make sure the new dir path exists before trying to rename files to avoid ENOENT errors. Also save errno when we encounter errors so that we can report the true error later rather than an error we may get while reverting changes. Also, it is OK if the ibex files don't exist, so check for that errno case. svn path=/trunk/; revision=24496
* remove debug printf.Not Zed2004-01-141-2/+0
| | | | | | | | | | | | | | | | 2004-01-14 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (local_getv): remove debug printf. ** See bug #52835. * camel-smime-context.c (sm_get_passwd): removed debugging. If we get called multiple times in a row, then forget the old password and re-prompt - it was a bad password. Zero out password memory too. svn path=/trunk/; revision=24208
* Use CAMEL_FODLER_NOCHILDREN rather than NOINFERIORS because NOINFERIORSJeffrey Stedfast2003-12-111-3/+3
| | | | | | | | | | | | 2003-12-10 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (get_folder_info): Use CAMEL_FODLER_NOCHILDREN rather than NOINFERIORS because NOINFERIORS means the folder cannot contain subfolders. However, our mbox structure always allows subfolders. (scan_dir): Same. svn path=/trunk/; revision=23913
* encode the address before sending it out, rather than using the raw/utf8Not Zed2003-12-091-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-12-09 Not Zed <NotZed@Ximian.com> * providers/smtp/camel-smtp-transport.c (smtp_send_to): encode the address before sending it out, rather than using the raw/utf8 version. * camel-internet-address.c (camel_internet_address_encode_address): check for quoting the local part of the address before outputting it. (cia_encode_addrspec): quote local part if need be. (camel_internet_address_encode_address): make folding optional based on whether inlen is null or not. * camel-mime-utils.[ch]: rename is_* to camel_mime_is_* and export the type functions. 2003-12-08 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-utils.c (imap_atom_specials): add } to the atom specials list. This isn't correct, but some busted servers expect it. Bug #50728. 2003-12-02 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (local_setv): remove some debug printfs. ** See bug #51576. * camel-url.c (camel_url_decode): robustify url decoding for bad input, addresses a crash. svn path=/trunk/; revision=23676
* Fixes bug #51881Jeffrey Stedfast2003-12-092-2/+53
| | | | | | | | | | | | | 2003-12-08 Jeffrey Stedfast <fejj@ximian.com> Fixes bug #51881 * providers/local/camel-mbox-store.c (delete_folder): Same. * providers/local/camel-local-store.c (delete_folder): Unlink the cmeta file too. svn path=/trunk/; revision=23675
* Remove hard coded disable deprecated flagsJP Rosevear2003-12-071-2/+1
| | | | | | | | 2003-12-06 JP Rosevear <jpr@ximian.com> * */Makefile.am: Remove hard coded disable deprecated flags svn path=/trunk/; revision=23658
* Treat parent_name == NULL and parent_name == "" the same.Jeffrey Stedfast2003-12-041-1/+1
| | | | | | | | | 2003-12-03 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (create_folder): Treat parent_name == NULL and parent_name == "" the same. svn path=/trunk/; revision=23609
* Fixed an exception to give a more meaningful description.Jeffrey Stedfast2003-11-181-12/+10
| | | | | | | | | | 2003-11-17 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (create_folder): Fixed an exception to give a more meaningful description. (get_folder_info): We always want to scan at least one level deep. svn path=/trunk/; revision=23406
* Fixed an exception to give a more meaningful description.Jeffrey Stedfast2003-11-181-1/+2
| | | | | | | | | 2003-11-17 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (create_folder): Fixed an exception to give a more meaningful description. svn path=/trunk/; revision=23397
* set flags in another place tooJeffrey Stedfast2003-11-151-0/+6
| | | | svn path=/trunk/; revision=23357
* Handle "" as a request for a full dirscan as well (not just NULL). MakesJeffrey Stedfast2003-11-152-19/+24
| | | | | | | | | | | | | | 2003-11-14 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (get_folder_info): Handle "" as a request for a full dirscan as well (not just NULL). Makes it consistant with other stores. (scan_dir): Set the fi->flags appropriately. * providers/local/camel-mbox-folder.c (camel_mbox_folder_get_full_path): Removed temporary hack. svn path=/trunk/; revision=23356
* Merge new-ui-branch into the trunk.Ettore Perazzoli2003-10-223-11/+25
| | | | svn path=/trunk/; revision=22966
* If the CREATE flag is set and the parent .sbd directory does not exist,Jeffrey Stedfast2003-09-241-0/+13
| | | | | | | | | | 2003-09-23 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-store.c (get_folder): If the CREATE flag is set and the parent .sbd directory does not exist, create it. svn path=/trunk/; revision=22677
* s/HSCAN_/CAMEL_MIME_PARSER_STATE_/g andJeffrey Stedfast2003-09-197-35/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-08-26 Jeffrey Stedfast <fejj@ximian.com> * camel-mime-parser.[c,h]: s/HSCAN_/CAMEL_MIME_PARSER_STATE_/g and s/_header_state/_camel_mime_parser_state/g * camel-filter-driver.c: Same. * camel-folder-summary.c: Here too. * camel-http-stream.c: And here. * camel-mime-message.c: ... * camel-mime-part-utils.c: ... * camel-mime-part.c: ... * camel-movemail.c: ... * camel-multipart-signed.c: ... * camel-multipart.c: ... * providers/local/camel-mbox-folder.c: ... * providers/local/camel-mbox-summary.c: ... * providers/local/camel-mh-summary.c: ... * providers/nntp/camel-nntp-summary.c: ... * providers/pop3/camel-pop3-folder.c: ... 2003-08-25 Jeffrey Stedfast <fejj@ximian.com> * camel-mime-utils.[c,h]: Namespaced. * camel-data-wrapper.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-digest-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-filter-driver.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-filter-search.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-folder-search.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-folder-summary.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-http-stream.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-http-stream.h: updated for namespace changed made to camel-mime-utils.[c,h] * camel-internet-address.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-medium.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-message.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-parser.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-part-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-part.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-movemail.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart-encrypted.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart-signed.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-search-private.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-types.h: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-store-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imapp/camel-imapp-utils.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-local-summary.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-maildir-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-mbox-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-spool-summary.h: updated for namespace changed made to camel-mime-utils.[c,h] * providers/nntp/camel-nntp-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/nntp/camel-nntp-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/pop3/camel-pop3-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/sendmail/camel-sendmail-transport.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/smtp/camel-smtp-transport.c: updated for namespace changed made to camel-mime-utils.[c,h] svn path=/trunk/; revision=22613
* Implement a temp hack so trunk works until we merge in new-ui-branch.Jeffrey Stedfast2003-09-171-10/+15
| | | | | | | | | | 2003-09-16 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-folder.c (camel_mbox_folder_get_full_path): Implement a temp hack so trunk works until we merge in new-ui-branch. svn path=/trunk/; revision=22594
* Implements CamelLocalFolder::get_full_path() (publicly namespaced so thatJeffrey Stedfast2003-09-135-51/+666
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-09-12 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-folder.c (camel_mbox_folder_get_full_path): Implements CamelLocalFolder::get_full_path() (publicly namespaced so that CamelMboxStore can re-use them). (camel_mbox_folder_get_meta_path): Same. * providers/local/camel-mbox-store.c (get_folder): Changed the way the path is constructed, since we now handle subdirectories and stuff. (delete_folder): Try deleting the Folder.sbd directory. We also need to manage our own meta files since CamelLocalStore's impl constructs paths differently than what we need. (create_folder): Implemented. (rename_folder): Implemented. (scan_dir): Scan an mbox tree (get_folder_info): Implemented using scan_dir(). * providers/local/camel-local-store.c (delete_folder): Set fi->url to the correct value, meaning we need to prefix it with the protocol and the folder_name is not actually part of the path, it is a separate component to the url. * providers/local/camel-local-folder.c (camel_local_folder_construct): Use the new class virtual method to construct the full folder path and all the meta files. (local_get_full_path): Implemented default get_full_path method. (local_get_meta_path): Implemented default get_meta_path method. svn path=/trunk/; revision=22557
* Need to copy the local properties list before passing it out, since it'sNot Zed2003-08-301-1/+1
| | | | | | | | | 2003-08-29 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (local_getv): Need to copy the local properties list before passing it out, since it's freed. svn path=/trunk/; revision=22418
* implement PERSISTENT_PROPERTIES, for index mode.Not Zed2003-08-282-12/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-08-27 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (local_getv): implement PERSISTENT_PROPERTIES, for index mode. * camel-object.c (cobject_state_read): Also add property reading, and bump version to 1. (cobject_state_write): add persistent property writing. 2003-08-26 Not Zed <NotZed@Ximian.com> * camel-folder.c (folder_getv): chain up properly. * camel-file-utils.c (camel_file_util_savename): helper to create a .#filename filename. * providers/local/camel-local-folder.c (camel_local_folder_construct): init meta-data for local folders. (local_getv): chain up properly, if args are not processed, rather than don't if they aren't. 2003-08-23 Not Zed <NotZed@Ximian.com> * camel-object.c (cobject_class_init): added a new event, meta_changed. (camel_object_meta_set, camel_object_meta_get): meta-data api. (camel_object_free_hooks): Free meta-data if it is set on the object. * providers/local/camel-local-folder.c (camel_local_folder_get_type): setup a property list for local folders, just 'index_body' at present. svn path=/trunk/; revision=22388
* temporarily reverting my camel namespace patches until after we merge in ↵Jeffrey Stedfast2003-08-277-35/+35
| | | | | | some of the other branches svn path=/trunk/; revision=22373
* s/HSCAN_/CAMEL_MIME_PARSER_STATE_/g andJeffrey Stedfast2003-08-273-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-08-26 Jeffrey Stedfast <fejj@ximian.com> * camel-mime-parser.[c,h]: s/HSCAN_/CAMEL_MIME_PARSER_STATE_/g and s/_header_state/_camel_mime_parser_state/g * camel-filter-driver.c: Same. * camel-folder-summary.c: Here too. * camel-http-stream.c: And here. * camel-mime-message.c: ... * camel-mime-part-utils.c: ... * camel-mime-part.c: ... * camel-movemail.c: ... * camel-multipart-signed.c: ... * camel-multipart.c: ... * providers/local/camel-mbox-folder.c: ... * providers/local/camel-mbox-summary.c: ... * providers/local/camel-mh-summary.c: ... * providers/nntp/camel-nntp-summary.c: ... * providers/pop3/camel-pop3-folder.c: ... svn path=/trunk/; revision=22365
* Namespaced.Jeffrey Stedfast2003-08-265-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-08-25 Jeffrey Stedfast <fejj@ximian.com> * camel-mime-utils.[c,h]: Namespaced. * camel-data-wrapper.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-digest-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-filter-driver.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-filter-search.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-folder-search.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-folder-summary.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-http-stream.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-http-stream.h: updated for namespace changed made to camel-mime-utils.[c,h] * camel-internet-address.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-medium.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-message.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-parser.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-part-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-mime-part.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-movemail.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart-encrypted.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart-signed.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-multipart.c: updated for namespace changed made to camel-mime-utils.[c,h] * camel-search-private.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * camel-types.h: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-store-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imap/camel-imap-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/imapp/camel-imapp-utils.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-local-summary.[c,h]: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-maildir-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-mbox-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/local/camel-spool-summary.h: updated for namespace changed made to camel-mime-utils.[c,h] * providers/nntp/camel-nntp-summary.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/nntp/camel-nntp-utils.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/pop3/camel-pop3-folder.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/sendmail/camel-sendmail-transport.c: updated for namespace changed made to camel-mime-utils.[c,h] * providers/smtp/camel-smtp-transport.c: updated for namespace changed made to camel-mime-utils.[c,h] svn path=/trunk/; revision=22355
* Get rid of the #ifdef ENABLE_THREADS since we no longer plan toJeffrey Stedfast2003-07-102-50/+44
| | | | | | | | | | | | | | | | | 2003-07-09 Jeffrey Stedfast <fejj@ximian.com> Get rid of the #ifdef ENABLE_THREADS since we no longer plan to support/maintain this. * providers/nntp/camel-nntp-store.c: Here. * providers/nntp/camel-nntp-newsrc.c: And here. * providers/nntp/camel-nntp-folder.c: Same. * providers/local/camel-local-folder.c: And here. svn path=/trunk/; revision=21778
* Updated for string-utils namespace changes.Jeffrey Stedfast2003-07-086-10/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-07-07 Jeffrey Stedfast <fejj@ximian.com> * camel-session.c (camel_session_init): Updated for string-utils namespace changes. * camel-provider.c: Updated for string-utils namespace changes. * camel-mime-part.c (init_header_name_table): Updated for string-utils namespace changes. * camel-mime-message.c (camel_mime_message_class_init): Updated for string-utils namespace changes. (camel_mime_message_init): Same. * camel-mime-filter-enriched.c (camel_mime_filter_enriched_class_init): Updated for string-utils namespace changes. * camel-folder-summary.c (camel_folder_summary_init): Updated for string-utils namespace changes. * camel-string-utils.[c,h]: Renamed from string-utils.[c,h] and also namespaced all functions. svn path=/trunk/; revision=21751
* Ensure cmdbuf is initialized to avoid compiler warning.Jeremy Katz2003-05-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-05-16 Jeremy Katz <katzj@redhat.com> * providers/smtp/camel-smtp-transport.c (smtp_helo): Ensure cmdbuf is initialized to avoid compiler warning. * providers/local/camel-mbox-summary.c (summary_header_load): Cast folder_size to uint32 to fix warning. (camel_mbox_summary_sync_mbox): Update for new API. * providers/imap/camel-imap-utils.c (parse_params): imap_parse_nstring expects size_t, not int (imap_body_decode): Likewise. * camel-stream-filter.c (do_read): presize needs to be size_t instead of int. (do_write): Likewise. * camel-seekable-substream.c (stream_read): Return ssize_t instead of int to match prototypes. (stream_write): Likewise. * camel-mime-part.c (construct_from_parser): len needs to be size_t instead of int. * camel-mime-parser.c (folder_scan_step): datalength needs to be a size_t* instead of an int* to make dependent APIs safe. (camel_mime_parser_step): Likewise. (folder_scan_content): Likewise. * camel-mime-parser.h: Likewise. * camel-mime-message.c (camel_mime_message_class_init): Use glib macro for pointer/int conversions. (construct_from_parser): Update for new API. * camel-folder-summary.c (camel_folder_summary_info_new_from_parser): Update len to be size_t for new API. (summary_build_content_info): Likewise. * camel-http-stream.c (http_get_headers): Likewise. * camel-mime-part-utils.c (simple_data_wrapper_construct_from_parser): Likewise. * camel-multipart-signed.c (signed_construct_from_parser): Likewise. * camel-multipart.c (construct_from_parser): Likewise. * camel-folder-search.c (match_words_index): Use glib macros for pointer/int conversions. * camel-html-parser.c (tokenise_setup): Likewise. (convert_entity): Likewise. * camel-block-file.c (block_hash_func): Likewise. (camel_block_file_get_block): Likewise. (camel_block_file_get_block): Likewise. (camel_block_file_detach_block): Likewise. * camel-session.c (session_thread_msg_new): Likewise. (session_thread_msg_free): Likewise. (session_thread_wait): Likewise. * camel-text-index.c (text_index_compress_nosync): Likewise. (text_index_compress_nosync): Likewise. (camel_text_index_validate): Likewise. * camel-vee-folder.c (vee_folder_remove_folder): Likewise. (unmatched_check_uid): Likewise. (folder_added_uid): Likewise. (vee_folder_build_folder): Likewise. (folder_changed_add_uid): Likewise. (folder_changed_remove_uid): Likewise. * providers/imap/camel-imap-search.c (imap_body_contains): Likewise. * providers/pop3/camel-pop3-folder.c (cmd_list): Likewise. (cmd_uidl): Likewise. * camel-data-cache.c (data_cache_init): Cast to CamelCopyFunc. Fixes a warning. svn path=/trunk/; revision=21220
* Only delete the index if it is non-NULL. Fixes bug #42763.Jeffrey Stedfast2003-05-161-2/+3
| | | | | | | | | 2003-05-13 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-folder.c (local_delete): Only delete the index if it is non-NULL. Fixes bug #42763. svn path=/trunk/; revision=21193
* ** for #40989Not Zed2003-04-191-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-04-17 Not Zed <NotZed@Ximian.com> ** for #40989 * camel-text-index.c (text_index_delete): delete the block file/key file directly, not just its files. * providers/local/camel-local-folder.c (local_delete): implement, just delete the index file if it exists. camel-store-delete-folder will delete other data (maybe it all should be done here). * camel-block-file.c (camel_key_file_finalise): keep lock around decrementing key file use count. (camel_key_file_delete): new function to delete the key file (& close it off). (key_file_use): if we've been deleted, always fail. (camel_block_file_finalise): only close the file if its a valid fd. (block_file_use): if we've been deleted, always fail. (camel_block_file_delete): delete the block file & close. (struct _CamelBlockFilePrivate): fix the !ENABLE_THREADS case to still compile this. svn path=/trunk/; revision=20894
* remove unused var.Not Zed2003-03-281-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2003-03-28 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (get_folder): remove unused var. * providers/imap/camel-imap-utils.c (imap_parse_list_response): moved an unused var to the #if 0'd out block. * providers/imap/camel-imap-store.c (parse_list_response_as_folder_info): remove unused vars. * camel-index-control.c (main): deifne camel_init() before using it. * camel-vee-store.c (vee_get_folder): removed unused var. * camel-stream-mem.c (stream_write): warning -> fixme. * camel-stream-filter.c (_CamelStreamFilterPrivate): Add a ; to the end of the struct definition. * camel-store.c (camel_store_delete_folder): remove unused var. (camel_store_rename_folder): " (camel_store_unsubscribe_folder): " * camel-mime-part.c (write_to_stream): Changed warning into a TODO. (construct_from_parser): removed warning, the code was fixed. * camel-mime-message.c (construct_from_parser): Remove the warning, the code was fixed. * camel-mime-filter-enriched.c (camel_mime_filter_enriched_new): Remove unused var. * camel-medium.c (camel_medium_get_header): Removed warning, and changed docs to reflect it. * camel-gpg-context.c (gpg_ctx_parse_status): handle MODE_EXPORT as a noop (warning). * camel-folder.c (get_message_user_tag): changed a warning into a fixme (its not that important). (camel_folder_get_message_user_tag): " * camel-data-cache.c (data_cache_finalise): removed unused vars. (data_cache_expire): " svn path=/trunk/; revision=20556
* Handle raw 8-bit From data "correctly". (The same way we handleDan Winship2003-03-214-76/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | raw 8-bit Subject data.) * camel-mime-utils.c (header_decode_mailbox): Take a charset arg and pass it to header_decode_string. (header_decode_address): Take a charset arg and pass it to header_decode_mailbox. (header_mailbox_decode): Likewise. (header_address_decode): Take a charset arg and pass it to header_decode_address. * camel-folder-summary.c (summary_format_address): Take a charset arg and pass to header_address_decode. (message_info_new, camel_message_info_new_from_header): Pass charset to summary_format_address * camel-internet-address.c (internet_decode): Update for header_address_decode change. (Unfortunately we don't have a charset to pass here.) * camel-mime-message.c (camel_mime_message_build_mbox_from): Move this here from camel-mbox-summary since the same functionality is needed by evolution-mail too (and update for header_address_decode change) * providers/local/camel-mbox-summary.c (camel_mbox_summary_build_from): Moved to CamelMimeMessage svn path=/trunk/; revision=20430
* Fixes for bug #39168Jeffrey Stedfast2003-03-064-22/+3
| | | | | | | | | | | | | | | | | | | | | | | | | 2003-03-06 Jeffrey Stedfast <fejj@ximian.com> Fixes for bug #39168 * providers/local/camel-spool-summary.c: Get rid of the empty private struct. * providers/local/camel-mbox-summary.c: Get rid of the empty private struct. * camel-vee-store.c: Get rid of the empty private struct. * camel-mime-filter-from.c: Get rid of the empty private struct. 2003-03-05 Jeffrey Stedfast <fejj@ximian.com> * providers/sendmail/camel-sendmail-transport.c (sendmail_send_to): Add a CRLF filter to the output stream to convert any CRLF sequences into plain old line-feeds to work around a bug in some local transport programs. svn path=/trunk/; revision=20187
* Undo jeff's changes.Not Zed2003-02-271-3/+7
| | | | | | | | | | | 2003-02-27 Not Zed <NotZed@Ximian.com> * camel-multipart-signed.c: Undo jeff's changes. * providers/local/camel-spool-store.c (scan_dir): Fix a paste-o in the object_bag_get key. svn path=/trunk/; revision=20084
* Define in terms of privincludedir. (camellibexecdir): Define in terms ofDan Winship2003-02-061-2/+1
| | | | | | | | | | | | | | | | | | * Makefile.am (libcamelincludedir): Define in terms of privincludedir. (camellibexecdir): Define in terms of privlibexecdir (libcamel_la_LDFLAGS): Remove -rpath. (automake will add that) * providers/imap/Makefile.am (libcamelimapincludedir): Define in terms of privincludedir. (INCLUDES): Remove -I$(includedir) * providers/local/Makefile.am: Likewise * providers/nntp/Makefile.am: Likewise * providers/pop3/Makefile.am: Likewise * providers/sendmail/Makefile.am: Likewise * providers/smtp/Makefile.am: Likewise svn path=/trunk/; revision=19775
* Update to the new $(BASE_VERSION)-versioned path. Likewise. Likewise.Ettore Perazzoli2003-01-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/Makefile.am (libcamelimapincludedir): Update to the new $(BASE_VERSION)-versioned path. * providers/smtp/Makefile.am (libcamelsmtpincludedir): Likewise. * providers/sendmail/Makefile.am (libcamelsendmailincludedir): Likewise. * providers/pop3/Makefile.am (libcamelpop3includedir): Likewise. * providers/nntp/Makefile.am (libcamelnntpincludedir): Likewise. * providers/local/Makefile.am (libcamellocalincludedir): Likewise. * camel-lock-client.c (camel_lock_helper_init): Use CAMEL_LIBEXECDIR instead of CAMEL_SBINDIR to find camel-lock-helper. * Makefile.am: Install camel-lock-helper and camel-index-control in $(libexec)/evolution/$(BASE_VERSION)/camel. Install libcamel.la in $privlibdir. (install-exec-hook): Update for the new location of camel-lock-helper. (libcamelincludedir): Version using $(BASE_VERSION). (INCLUDES): Define CAMEL_LIBEXECDIR. svn path=/trunk/; revision=19554
* Replace calls to g_string_sprintfa() with g_string_append_printf() sinceJeffrey Stedfast2002-12-1810-63/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-12-17 Jeffrey Stedfast <fejj@ximian.com> * providers/imap/camel-imap-utils.c: Replace calls to g_string_sprintfa() with g_string_append_printf() since the former seems to have been deprecated. * providers/imap/camel-imap-search.c: Same. * providers/imap/camel-imap-folder.c: Here too. * providers/local/camel-mbox-summary.c: And here. * providers/local/camel-local-summary.c: Replace g_string_sprintf() with g_string_printf(). * camel-data-cache.c (data_cache_expire): Replace g_string_sprintf() with g_string_printf(). * camel-url.c: Replace calls to g_string_sprintfa() with g_string_append_printf() since the former seems to have been deprecated. * camel-service.c: Same. * camel-mime-utils.c: Here too. svn path=/trunk/; revision=19154
* Use a bag instead of a hashtable to track the cache streams.Not Zed2002-12-094-29/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-12-07 Not Zed <NotZed@Ximian.com> * camel-data-cache.c (data_cache_init): Use a bag instead of a hashtable to track the cache streams. (data_cache_finalise): Same. (free_busy): No longer needed. (data_cache_expire): use bag instead of hashtable. (stream_finalised): No longer required. (camel_data_cache_add): objectbagise (camel_data_cache_get): " (camel_data_cache_remove): " (data_cache_path): Set the now expired date before running expiry, so it plays better with multiple threads. Still a couple of harmless races. 2002-12-06 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (scan_dir): folders -> object bag. (get_folder_info_mbox): folders -> object bag. * providers/local/camel-mh-store.c (folder_info_new): folders -> object bag. * providers/local/camel-maildir-store.c (scan_dir): folders -> object bag. * providers/local/camel-local-store.c (rename_folder): folders -> object bag. * camel-private.h (CamelStorePrivate): Remove 'cache' lock, handled by the objectbag. * providers/imap/camel-imap-store.c (copy_folder): Removed. (imap_store_refresh_folders): folders -> object bag. (get_folder_counts): folders -> object bag. * camel-vee-store.c (vee_get_folder): changes for folders objectbag. (vee_get_folder_info): Change to use folders objectbag. Also, dont refresh the base folder if we're in FAST mode. (build_info): Removed, no longer needed. (vee_rename_folder): Fixed for folders objectbag. * camel-store.c (camel_store_init): init the folders objectbag. (camel_store_finalize): Destroy the folders object bag. (folder_matches): (folder_finalize): Removed, now handled implicitly by the objectbag. (camel_store_get_folder): object bag changes. (camel_store_delete_folder): " (get_subfolders): Removed, now handled without a callback. (camel_store_rename_folder): Changed to use object bag of folders. (trash_add_folder): Removed. (init_trash): use folders object bag. (copy_folder_cache): (sync_folder): Removed, no longer needed. Weird arsed code anyway. (store_sync): Use folder object bag instead of hashtable. (camel_store_unsubscribe_folder): " (camel_store_init): remove cache_lock init, no longer used. (camel_store_finalize): Same for cleanup. 2002-12-05 Not Zed <NotZed@Ximian.com> * camel-store.h (struct _CamelStore): change folders from a hashtable into a CamelObjectBag. * camel-object.c (camel_object_ref): Use type_lock instead of class lock for ref counting. (camel_object_unref): Use type_lock instead of class lock for unref. (camel_object_unref): If the object is 'bagged', then also look hooks, and remove it from any bags. (camel_object_bag_new): (camel_object_bag_destroy): (camel_object_bag_add): (camel_object_bag_get): (camel_object_bag_remove_unlocked): (camel_object_bag_list): (camel_object_bag_abort): (camel_object_bag_remove): New functions to implement a utility object which can manage a 'bag' of weakly ref'd children in an atomic & threadsafe way. svn path=/trunk/; revision=19056
* Use g_strerror when setting an exception string (we need it to be inJeffrey Stedfast2002-11-1115-168/+207
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-11-11 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-spool-summary.c (spool_summary_sync_full): Use g_strerror when setting an exception string (we need it to be in UTF-8). (spool_summary_check): Here too. * providers/local/camel-spool-store.c (construct): Use g_strerror when setting an exception string (we need it to be in UTF-8). (get_folder): Same. (scan_dir): Here too. * providers/local/camel-spool-folder.c (spool_lock): Use g_strerror when setting an exception string (we need it to be in UTF-8). * providers/local/camel-mh-summary.c (mh_summary_check): Use g_strerror when setting an exception string (we need it to be in UTF-8). * providers/local/camel-mh-store.c (delete_folder): Use g_strerror when setting an exception string (we need it to be in UTF-8). * providers/local/camel-mbox-summary.c (summary_update): Use g_strerror when setting an exception string (we need it to be in UTF-8). (mbox_summary_sync_full): Here too. (mbox_summary_sync_quick): Same. (mbox_summary_sync): Also here. (camel_mbox_summary_sync_mbox): Again here. * providers/local/camel-mbox-folder.c (mbox_lock): Use g_strerror when setting an exception string (we need it to be in UTF-8). (mbox_append_message): Same. (mbox_get_message): Here too. * providers/local/camel-maildir-summary.c (maildir_summary_load): Use g_strerror when setting an exception string (we need it to be in UTF-8). (maildir_summary_check): Same. * providers/local/camel-maildir-store.c (get_folder): Use g_strerror when setting an exception string (we need it to be in UTF-8). (delete_folder): Same. (delete_folder): Here too. * providers/local/camel-local-summary.c (local_summary_sync): Use g_strerror when setting an exception string (we need it to be in UTF-8). * providers/local/camel-local-store.c (get_folder): Use g_strerror when setting an exception string (we need it to be in UTF-8). (create_folder): Same. (xrename): Here too. (rename_folder): And here. (delete_folder): Also here. * camel-provider.c (camel_provider_init): For debugging printfs, we want to use normal strerror (we want locale charset, not UTF-8). * camel-movemail.c (camel_movemail): Use g_strerror when setting an exception string (we need it to be in UTF-8). (movemail_external): Same. (camel_movemail_copy_file): Here too. (camel_movemail_solaris): Also here. * camel-mime-utils.c (rfc2047_decode_word): For debugging printfs, we want to use normal strerror (we want locale charset, not UTF-8). (header_encode_param): Same. * camel-mime-part-utils.c (convert_buffer): For debugging printfs, we want to use normal strerror (we want locale charset, not UTF-8). * camel-lock-client.c (camel_lock_helper_init): Use g_strerror when setting an exception string (we need it to be in UTF-8). * camel-data-cache.c (camel_data_cache_remove): Use g_strerror when setting an exception string (we need it to be in UTF-8). * camel-tcp-stream-raw.c (flaky_tcp_write): For debugging printfs, we want to use normal strerror (we want locale charset, not UTF-8). (flaky_tcp_read): Same. * camel-gpg-context.c (gpg_ctx_op_step): For debugging printfs, we want to use normal strerror (we want locale charset, not UTF-8). * camel-service.c (camel_gethostbyname): Use g_strerror when setting an exception string (we need it to be in UTF-8). * camel-lock.c (camel_lock_dot): Use g_strerror when setting an exception string (we need it to be in UTF-8). (camel_lock_fcntl): Same. svn path=/trunk/; revision=18689
* Use g_path_get_basename instead of g_strdup (g_basename (filename)).Jeffrey Stedfast2002-11-021-1/+1
| | | | | | | | | 2002-11-01 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-store.c (delete_folder): Use g_path_get_basename instead of g_strdup (g_basename (filename)). svn path=/trunk/; revision=18498
* Treat spool as a local folder, so the ref checks work right.Not Zed2002-09-261-3/+1
| | | | | | | | | | | | 2002-09-26 Not Zed <NotZed@Ximian.com> * tests/folder/test2.c (main): Treat spool as a local folder, so the ref checks work right. * providers/local/camel-spool-store.c (get_folder): Use creat() instead of open() to create file. svn path=/trunk/; revision=18231
* Implement FOLDER_CREATE flag. (scan_dir): Dont free name on exception, itsNot Zed2002-09-263-20/+87
| | | | | | | | | | | | | | | | | | | | 2002-09-26 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (get_folder): Implement FOLDER_CREATE flag. (scan_dir): Dont free name on exception, its alloca'd. (scan_dir): If we start scanning from a file, just add that directly. (scan_dir): Allow empty files to also show up in folder list, as well as files starting with "From ". * providers/local/camel-spool-folder.c (camel_spool_folder_new): Check folder != NULL before writing to it. * providers/local/camel-local-store.c (create_folder): Handle a parent of NULL for creating top-level dirs. Part of #31186. svn path=/trunk/; revision=18230
* Do proper error checking and return -1 on fail.Jeffrey Stedfast2002-09-112-12/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | 2002-09-10 Jeffrey Stedfast <fejj@ximian.com> * camel-folder-summary.c (perform_content_info_save): Do proper error checking and return -1 on fail. (camel_folder_summary_save): Check the return of perform_content_info_save and a few other output calls within the message_info_save loop. If any of them fail, save errno, close the file, and return -1. If we finish the loop without fail, fflush the stream and then fsync (fflush only flushes user-space buffers, you still need to fsync afterward to flush the data to disk). If either fail, treat it as an exception by saving errno, closing the stream, and returning -1. I suspect that this also fixes bug #30150 because the old code would fclose if fflush or fclose failed in the check after the loop (man fclose(3) states that any further calls using the stream (even another call to fclose) will have undefined behaviour no matter what the first fclose call returned). * providers/local/camel-local-summary.c (camel_local_summary_init): Don't malloc a private struct of 0 size. svn path=/trunk/; revision=18036
* Change the case sensitive search of subject to expect case insensitiveNot Zed2002-08-292-11/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-08-29 Not Zed <NotZed@Ximian.com> * tests/folder/test3.c: Change the case sensitive search of subject to expect case insensitive results, as the behaviour has changed. (main): Made the search content before sync nonfatal. its something that needs to be fixed but not practical concern in evolution. * camel-block-file.c (block_file_validate_root): Only spit out the invalid root warnings if the file isn't empty. * camel-text-index.c (text_index_compress_nosync): Swap the path as well when we compress. * camel-mime-parser.c (folder_scan_content): Treat the end of file as a boundary if we're scanning From lines, and drop the last \n. (folder_scan_init_with_fd): Dont pre-read from the fd, and init eof. (folder_scan_init_with_stream): Similar. (folder_read): Handle eof, and set eof on 0 read. (folder_seek): Dont pre-read after a seek, and reset eof flag. (camel_mime_parser_init_with_fd): Fix doco, no pre-read occurs anymore. (camel_mime_parser_init_with_stream): Same. * providers/local/camel-mbox-summary.c (camel_mbox_summary_sync_mbox): Add a \n to end of content of each message, not at start. * providers/local/camel-mbox-folder.c (mbox_append_message): Instead of appending "\nFrom " to a mailbox, start with "From ", and append a \n after the message always. For better mutt/elm compatability. Also, unlock after we've stat'd. (mbox_append_message): Set the message's from_pos exactly as the mbox size. svn path=/trunk/; revision=17921
* Add CAMEL_MESSAGE_ANSWERED_ALL, for folders that can distinguish aDan Winship2002-08-051-1/+2
| | | | | | | | | | | * camel-folder-summary.h (CamelMessageFlags): Add CAMEL_MESSAGE_ANSWERED_ALL, for folders that can distinguish a reply-to-sender from a reply-to-all. (eg, Exchange) * providers/local/camel-local-folder.c (local_init): Add ANSWERED_ALL to permanent_flags too. svn path=/trunk/; revision=17694
* Clear the summary after building the 'removed uid' list.Not Zed2002-08-021-1/+1
| | | | | | | | | 2002-08-02 Not Zed <NotZed@Ximian.com> * providers/local/camel-mbox-summary.c (mbox_summary_check): Clear the summary after building the 'removed uid' list. svn path=/trunk/; revision=17686
* revert jeff's patch below, and do it slightly differently, and stop theNot Zed2002-08-021-26/+37
| | | | | | | | | | | | | | | | | | 2002-08-02 Not Zed <NotZed@Ximian.com> * camel-folder-summary.c (message_info_load): revert jeff's patch below, and do it slightly differently, and stop the auto-reformatting bullshit. 2002-08-02 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-summary.c (message_info_new): If we get a duplicate, just re-use the old info. (remove_summary): Add any removed to a change list. (maildir_summary_check): If we find new ones in 'cur' track them in the change list. Removed FIXME about it. For #18348. svn path=/trunk/; revision=17685
* If the path exists and is a directory, return non-NULL. Missed this beforeJeffrey Stedfast2002-07-274-10/+10
| | | | | | | | | | 2002-07-26 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-store.c (get_folder): If the path exists and is a directory, return non-NULL. Missed this before which is how we could return NULL even on success. Oops. svn path=/trunk/; revision=17618
* Revert Jeff's previous change, it broke local folders. UninitializedPeter Williams2002-07-274-11/+13
| | | | | | | | | 2002-07-26 Peter Williams <peterw@ximian.com> * Revert Jeff's previous change, it broke local folders. Uninitialized exceptions or something. svn path=/trunk/; revision=17605
* ioops, this file tooJeffrey Stedfast2002-07-261-3/+2
| | | | svn path=/trunk/; revision=17600
* If we're gonna do an elite hack, lets do it right.Jeffrey Stedfast2002-07-263-10/+9
| | | | | | | | | | | | | | | | | | | | | 2002-07-25 Jeffrey Stedfast <fejj@ximian.com> If we're gonna do an elite hack, lets do it right. * providers/local/camel-local-store.c (get_folder): On success, return non-NULL so that our caller doesn't have to depend on 'ex' being non-NULL in order to work correctly. * providers/local/camel-mbox-store.c (get_folder): Don't bother checking if an exception was set, just use the return value of camel-local-store's get_folder. * providers/local/camel-maildir-store.c (get_folder): Same as the mbox change. * providers/local/camel-mh-store.c (get_folder): Here too. svn path=/trunk/; revision=17599
* When writing the summary, use TRUNC flag, duh. Also, write to a temp fileNot Zed2002-07-241-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | 2002-07-25 Not Zed <NotZed@Ximian.com> * camel-folder-summary.c (camel_folder_summary_save): When writing the summary, use TRUNC flag, duh. Also, write to a temp file first, and rename when closed successfully, and check ferror() and fclose() against 0 rather than -1. * providers/local/camel-mbox-summary.c (summary_update): Decrement i if we remove the summary item so we dont skip every 2nd one. * camel-mime-utils.c (header_decode_mailbox): Use rfc2047_decode_word explicitly incase we just found an encoded word. Stops us re-decoding the string twice, which fixes memory corruption in #26330 when the HUGE string is used later. 2002-07-24 Not Zed <NotZed@Ximian.com> * camel-partition-table.c (camel_key_table_next): Didn't unlock if we exited on an empty key list. svn path=/trunk/; revision=17570
* Changed the mbox and spool provider descriptions to try and be more clear.Jeffrey Stedfast2002-07-161-2/+2
| | | | | | | | | | | | | | 2002-07-15 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c: Changed the mbox and spool provider descriptions to try and be more clear. I'm not sure I like the mention of Evolution in the mbox provider description, but there was no other way to make it clear that it MOVED mail out of the mbox folder into a folder managed by Evolution without mentioning Evolution. *sigh* Anyways, to me "retrieve" means move, but apparently this isn't clear to the weak minded. svn path=/trunk/; revision=17464
* If we get an exception from the child sync, update the exception string soNot Zed2002-07-031-1/+2
| | | | | | | | | | | | | | | | | | | | 2002-07-03 Not Zed <NotZed@Ximian.com> * camel-vee-folder.c (vee_sync): If we get an exception from the child sync, update the exception string so we know where it really was. * camel-vee-store.c (change_folder): Util to emit created/deleted events. (vee_get_folder): If the folder has path elements, and its parents dont exist, create dummy no-select nodes. This is for bug #4246. (vee_delete_folder): Use change_folder() to save code. * providers/local/camel-mbox-folder.c (mbox_set_message_flags): Only set xevchange if we're storing status headers in pine format, so we dont do a full sync every time any flag changes. svn path=/trunk/; revision=17360
* Remove the #include for camel-spoold-store.hJeffrey Stedfast2002-06-261-1/+0
| | | | | | | | | 2002-06-25 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c: Remove the #include for camel-spoold-store.h svn path=/trunk/; revision=17285
* Include <sys/time.h> for struct timeval.Not Zed2002-06-2618-2403/+888
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-06-26 Not Zed <NotZed@Ximian.com> * camel-gpg-context.c: Include <sys/time.h> for struct timeval. * providers/local/camel-local-provider.c (camel_provider_module_init): Removed spoold provider. The spool provider does it now. 2002-06-25 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-folder.c (camel_spool_folder_new): Support a new xstatus option - folders update/honour the Status/X-Status headers in addition to X-Evolution. * providers/local/camel-local-summary.c (camel_local_summary_write_headers): If supplied with an additional status or xstatus arg, write a Status header and/or X-Status. Also fix the case of properly terminating the headers if an xev line isn't supplied. * providers/local/Makefile.am (libcamellocalinclude_HEADERS,SOURCES): Removed spoold-store.[ch]. * providers/local/camel-local-provider.c (camel_provider_module_init): For the spoold type, just use the spool store instead. * providers/local/camel-spool-store.h: Added a type field, so the 1 store can implement different types without having to subclass. * providers/local/camel-spool-store.c (camel_spool_store_get_toplevel_dir): Removed, inherits from local store now. (construct): If we're pointing to a file, treat it as mbox mode, otherwise treat it as 'elm' mode. (get_folder): Only test for INBOX in mbox mode. (get_folder_info_elm): (get_folder_info_mbox): Two alternatives for getting folder info, depending on the type of folder we're looking at. (get_folder_info_mbox): Make the url include the protocol. (scan_dir): " * providers/local/camel-spoold-store.c (camel_spoold_store_get_toplevel_dir): Removed, inherits from local store now. * camel-folder.c (get_message_user_tag): Dont use a g_return_if_fail for info==NULL. This is not an error. (set_message_user_tag): And same here. (set_message_user_flag): Sigh, and here. (get_message_user_flag): And here. (set_message_flags): and here ... (get_message_flags): Dum de dum, de done at last. * providers/local/camel-mbox-folder.c (mbox_get_message): Check for new messages whenever we retrieve one. In the common no-update case, this is a single stat. (mbox_get_message): If we need to rescan, then force a full rescan to make sure it does the right thing. (mbox_get_message): Cleanup the exception handling a bit, if we do get an error, propagate any folder changes anyway as well. (mbox_set_message_user_flag): Argh more of these stupid g_returns taht shouldn't be. (mbox_set_message_user_tag): Here too. (mbox_set_message_flags): If the read flag is being changed, mark it as an xevchange (i.e. Status line change). * providers/local/camel-mbox-summary.c (summary_rebuild): Merged into summary_update. (summary_update): Changed to allow it to update existing lists of messages without clearing out the summary. (mbox_summary_check): Dont clear the summary, just re-scan. (message_info_new): Attempt to support the 'Status: RO' elm/pine thing. (camel_mbox_summary_encode_status): (camel_mbox_summary_decode_status): Util functions for creating/parsing the Status line. (camel_mbox_summary_sync_mbox): Write out the status line if we're going to try support it. (camel_mbox_summary_xstatus): Implement option to control read/write of (x-)status. (message_info_new): Do x-status stuff based on run-time option. (camel_mbox_summary_sync_mbox): " (mbox_summary_add): If x-status enabled, then always add status/x-status headers to message. * camel-folder-summary.c (summary_assign_uid): If the messageinfo is already in the summary, AND is the same messageinfo, dont do anything, return a value to indicate this. (camel_folder_summary_add): Do nothing if this info already in the summary, so we can perform updates. 2002-06-24 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-summary.c (camel_local_summary_check_force): New method to force the next summary check to be a full check, set if a mismatch occurs. * camel-folder-summary.c (camel_folder_summary_load): If we have no summary path set, dont do any i/o, rather than abort. (camel_folder_summary_save): " (camel_folder_summary_header_load): " * providers/local/camel-spool-store.h: Inherit from camel mbox store, even if we override almost everything. * providers/local/camel-local-folder.c (camel_local_folder_construct): If the base path points to a file, use that as the folder path as well. * providers/local/camel-spool-folder.h: Inherit from camel-mbox-folder. * providers/local/camel-spool-summary.c (spool_summary_sync_full): Use camel_mbox_summary_sync_mbox to do most of the work. * providers/local/camel-spool-summary.[ch]: Make spool-summary inherit from mbox summary rather than foldersummary. * providers/local/camel-mbox-summary.c (mbox_summary_sync): Make sync_full/quick virtual methods. (camel_mbox_summary_sync_mbox): The full sync method put into a simple function that sync's from fd to fd. (mbox_summary_sync_full): Use summary_sync_mbox to do the real work. (mbox_summary_check): Create removed events if the folder gets cleared. Also, dont clear the summary before a rebuild, try to merge. svn path=/trunk/; revision=17284
* Updated to use ctx->sign_protocol rather than ctx->protocol.Jeffrey Stedfast2002-06-151-1/+1
| | | | | | | | | | | | | | 2002-06-14 Jeffrey Stedfast <fejj@ximian.com> * camel-multipart-signed.c: Updated to use ctx->sign_protocol rather than ctx->protocol. * camel-cipher-context.h: Add an ecnryption protocol member. * camel-pgp-context.c (camel_pgp_context_init): Set the encryption protocol. svn path=/trunk/; revision=17186
* Remove the CONF_DEFAULT_PATH entry, as this is handled by the url configNot Zed2002-06-066-33/+469
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-06-04 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-provider.c: Remove the CONF_DEFAULT_PATH entry, as this is handled by the url config stuff. This made it basically impossible to configure any local folder from the gui. * providers/local/camel-local-folder.c (local_refresh_info): Force a refresh. Should work for all local folders to force them to refresh. * providers/local/camel-maildir-folder.c (maildir_refresh_info): Removed, moved into camel-local-folder. * providers/local/camel-mh-summary.c (mh_summary_next_uid_string): Once we assign or get a uid, tell the summary of this, so the next uid we get will be higher than any previously. * camel-object.c (camel_object_ref, camel_object_unref): I got sick of casting, these now take void * like they should, and perform their own run-time type checking. * providers/local/camel-mh-store.c (recursive_scan): Changed to use stat, not lstat (*shrug* maybe someone wants to softlink their maildir tree?). (inode_hash): (inode_equal): (inode_free): Copied from camel-maildir store (should put into camel-local-store or utils?). (recursive_scan): Changed to check for re-visiting inodes. Also, it builds the tree itself, rather than using folder_info_build. (add_folder): Changed to folder_info_new. (recursive_scan): Properly honour the recursive flag. Also, lookup unread count from folder. (folder_info_new): Init unread message count to -1, since we dont know yet. (folder_info_new): Take the name as an argument, and perform the merging here. (folders_update): Util func to add/remove folders from .folders file. I'm assuming its sorted. (get_folder): Add the folder to .folders if we created a new one, and if it exists. (delete_folder): Remove from .folders, etc. (folders_scan): If we have a .folders file, read and use that instead. (recursive_scan): Handle scanning from a particular directory properly. (rename_folder): Implement so we can track any changes to the .folders file if its turned on. ** Applied patch below from Greg Hudson. 2002-05-10 Greg Hudson <ghudson@mit.edu> * camel-mh-store.c (get_inbox, get_folder_info, recursive_scan, add_folder): Implement support for MH stores. * camel-mh-summary.c (mh_summary_check, sort_uid_cmp): Sort MH messages by message number (uid), like we sort maildir messages by date. * camel-local-provider.c (mh_provider): Turn on source and store flags. svn path=/trunk/; revision=17130
* setup/free the mech string.Not Zed2002-06-031-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-06-02 Not Zed <NotZed@Ximian.com> * camel-sasl.c (camel_sasl_new): (camel_sasl_finalize): setup/free the mech string. * camel-sasl.h: Added 'mech' mechanism string. 2002-06-01 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-folder.c (imap_getv): Implement. Only the object_description arg. (camel_imap_folder_get_type): Init parent_class holder. * providers/local/camel-local-folder.c (local_getv): Implement, object_description arg. * camel-folder.c (folder_getv): Implement, add a bunch of args you can get -> camel_folder_get_unread_count etc will be going RSN i hope. (camel_folder_finalize): Free cached description string. * camel-object.c (cobject_getv): Implement CAMEL_OBJECT_ARG_DESCRIPTION, just return the classname of the object. (camel_object_getv): (camel_object_get): (camel_object_setv): (camel_object_set): Take object = void *, to simplify usage. (camel_object_setv): Removed unecessary locals. (camel_object_getv): Same. (camel_object_free): New method, free an arg, upto implementations whether args are static/const or not. (cobject_free): Implement a dummy do nothing free. 2002-05-31 Not Zed <NotZed@Ximian.com> * camel-vee-folder.c (camel_vee_folder_get_location): new function to get the real location (folder) (and uid) of a vfolder object. Using the folderinfo, since we already have it, maybe it should use the uid. svn path=/trunk/; revision=17073
* Implement. Run a summary check to update for any newly arrived messages.Not Zed2002-05-292-1/+20
| | | | | | | | | | | | | 2002-05-28 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-folder.c (maildir_refresh_info): Implement. Run a summary check to update for any newly arrived messages. * providers/local/camel-maildir-store.c (scan_dir): If we have a folder, execute a refresh_info on it, to suck in any new stuff. svn path=/trunk/; revision=17029
* Add a "char **appended_uid" argument, for the caller to optionally pass inDan Winship2002-05-144-8/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-folder.c (camel_folder_append_message): Add a "char **appended_uid" argument, for the caller to optionally pass in a variable to receive the UID of the appended message (if the provider knows it). (camel_folder_transfer_messages_to): Likewise, add "GPtrArray **transferred_uids" (transfer_messages_to): Update default implementation to handle transferred_uids. * camel-disco-folder.c (disco_append_message, disco_transfer_messages_to): Update for API changes. * camel-disco-diary.c (camel_disco_diary_replay): Update the diary's temporary uid->real uid map when replaying appends and transfers. * providers/imap/camel-imap-folder.c (imap_append_offline, imap_append_online, imap_transfer_offline): Pass back the new UIDs, when requested and available. (imap_append_resyncing): Pass back the new UIDs when requested and available. Remove the diary uidmap managing code since CamelDiscoDiary can handle that itself now. (imap_transfer_online, imap_transfer_resyncing): Update for new APIs, but don't actually pass back the new UIDs yet. (It's tricky since the COPYUID response may not be in the same order as the input uids.) * providers/local/camel-maildir-folder.c (maildir_append_message): Pass back the new UID if requested. * providers/local/camel-mbox-folder.c (mbox_append_message): Likewise. * providers/local/camel-mh-folder.c (mh_append_message): Likewise. * providers/local/camel-spool-folder.c (spool_append_message): Likewise. * camel-digest-folder.c (digest_append_message, digest_transfer_messages_to): Update for API changes. * camel-filter-driver.c (camel_filter_driver_filter_message, do_copy, do_move): Update for API changes. * camel-vee-folder.c (vee_append_message, vee_transfer_messages_to): Likewise. * camel-vtrash-folder.c (vtrash_append_message, vtrash_transfer_messages_to): Likewise. svn path=/trunk/; revision=16765
* Check for LOGIN xxxx as well if debug is on, so we dont print passwords toNot Zed2002-05-074-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-05-07 Not Zed <NotZed@Ximian.com> * camel-remote-store.c (remote_send_string): Check for LOGIN xxxx as well if debug is on, so we dont print passwords to evolution logs. * providers/imap/camel-imap-utils.c (imap_is_atom_char): This was really broken. 1. isprint() is locale dependent, and 2. it looked up an 8 bit value in a 7 bit table without truncating it. I've removed the isprint() stuff and just put it directly into the special table, which i've expanded to the right size too. * providers/imap/*: Applied patch from Preston Elder <prez@magick.tm> to make camel only use literals if it needs to for simple strings. Changed slightly to use imap_is_atom() and more consistent formatting. providers/imap/camel-imap-utils.c (imap_is_atom): Chagned from imap_needs_quoting(). ** Merged in camel-object2 branch. Simpler camelobject implementation + object args interface. * camel.c (camel_init): Call camel_object_get_type() to make sure camel_object_type is initialised. * camel-object.h (CAMEL_OBJECT_TYPE): Changed to return global camel_object_type pointer, not call camel_object_get_type. svn path=/trunk/; revision=16701
* We want to set unread_count to get_unread_message_count, notNot Zed2002-04-291-2/+1
| | | | | | | | | | | 2002-04-29 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (get_folder_info): We want to set unread_count to get_unread_message_count, not get_message_count(). Might fix #17174. Also removed FIXME: as it was fixed. svn path=/trunk/; revision=16629
* Don't link to libibex.a anymore.Jeffrey Stedfast2002-04-271-2/+1
| | | | | | | | | | | | 2002-04-26 Jeffrey Stedfast <fejj@ximian.com> * providers/local/Makefile.am: Don't link to libibex.a anymore. * providers/nntp/Makefile.am: Same. * providers/imap/Makefile.am: And again here. svn path=/trunk/; revision=16609
* Configure the default paths for mh, mbox, maildir, spools, etc.Jeffrey Stedfast2002-04-251-15/+52
| | | | | | | | | | | | | 2002-04-24 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c (camel_provider_module_init): Configure the default paths for mh, mbox, maildir, spools, etc. * camel-provider.h: Add a CAMEL_PROVIDER_CONF_LABEL enum and define some default CamelProviderConfEntry macros. svn path=/trunk/; revision=16580
* If we get a failure, make sure we set an exception.Not Zed2002-04-181-2/+6
| | | | | | | | | | | | | | 2002-04-18 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-store.c (rename_folder): If we get a failure, make sure we set an exception. * camel-text-index.c (camel_text_index_rename): If the file doesn't exist, just assume it never did, dont return failure. (text_index_rename): Add '.index' to the path name we're using, since we dont get it passed in. svn path=/trunk/; revision=16505
* Added #include <sys/types.h> for dirent.h which needs it on MacOS X.Jeffrey Stedfast2002-04-152-0/+2
| | | | | | | | | | | | | | | | | | | 2002-04-14 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-spoold-store.c: Added #include <sys/types.h> for dirent.h which needs it on MacOS X. * providers/local/camel-maildir-store.c: Same. * providers/nntp/camel-nntp-store.c: Same. * providers/imap/camel-imap-message-cache.c: Same. * camel-provider.c: Same. * camel-data-cache.c: Same. svn path=/trunk/; revision=16466
* If the last message(s) were deleted, and we had any messages output,Not Zed2002-04-111-0/+7
| | | | | | | | | | | | | | | | | 2002-04-11 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-summary.c (spool_summary_sync_full): If the last message(s) were deleted, and we had any messages output, account for the lost \n of the following From line by adding an extra \n. fix for #8214. 2002-04-10 Not Zed <NotZed@Ximian.com> * camel-mime-part-utils.c (convert_buffer): If we get a 0 length input, return a 0 lenght output as valid - fixes bugs with some iconv impl and its simpler anyway. svn path=/trunk/; revision=16438
* make service_cache be an array of CAMEL_NUM_PROVIDER_TYPES elements so youDan Winship2002-04-041-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-provider.h (CamelProvider): make service_cache be an array of CAMEL_NUM_PROVIDER_TYPES elements so you can have a single provider offer both stores and transports. (Eg, Exchange, NNTP) * providers/imap/camel-imap-provider.c: Don't initialize service_cache here. (The session code can do it itself since the url_hash and url_equal functions are stored as part of the provider.) * providers/nntp/camel-nntp-provider.c: Likewise. * providers/local/camel-local-provider.c: Likewise. * providers/pop3/camel-pop3-provider.c: Likewise. * providers/sendmail/camel-sendmail-provider.c: Likewise. * providers/smtp/camel-smtp-provider.c: Likewise. * camel-session.c (register_provider): Initialize the provider's service cache(s) here. (camel_session_class_init): Don't initialize. vee_provider.service_cache here. (camel_session_destroy_provider): Update to destroy multiple service_caches. (service_cache_remove, get_service): Tweak these a bit to deal with multiple service_caches. svn path=/trunk/; revision=16330
* Turn indexing back on, fingers crossed ...Not Zed2002-04-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | 2002-04-03 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (camel_local_folder_construct): Turn indexing back on, fingers crossed ... * camel-block-file.c (sync_nolock): #!@$@$#@~#$ DF@#$!Q@$#!@$#!#%. Well it helps if we're iterating a list to iterate the node pointer ... * camel-text-index.c (text_index_sync): Sync the key tables explcitly. (text_index_sync): Debug out frag info. (camel_text_index_dump): Added a (rather large, but optional) raw dumping mode for debugging purposes. * camel-partition-table.c (camel_key_table_finalise): Sync root block when done. svn path=/trunk/; revision=16329
* Temporarily disable indexing.Not Zed2002-04-021-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-04-02 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-folder.c (camel_local_folder_construct): Temporarily disable indexing. 2002-03-28 Not Zed <NotZed@Ximian.com> * camel-partition-table.c (camel_key_table_lookup): Change range checking assert to a warning. * providers/pop3/camel-pop3-folder.c (pop3_finalize): Make sure we flush out all outstanding commands before finalising, stops being finalised while outsanding requests are processed by the store finalise. (pop3_get_message): Instead of pre-fetching all messages, just pre-fetch a maxiumum number at any one time, stops us running out of cache fd's. * providers/nntp/camel-nntp-folder.c (nntp_folder_init/finalise): Setup priv data + locks, & free. * providers/imap/camel-imap-folder.c (imap_rescan): Batch all message_chagned events into a single folder_changed event (otherwise updates can be >>> expensive, like >5 hours for 80K messages changing!). Alternately it could use folder freeze/unfreeze perhaps. 2002-03-27 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-store.c (imap_keepalive): Pass an exception to called code so it behaves properly since it uses the passed exception to check returns. svn path=/trunk/; revision=16319
* Use -avoid-version instead of -version-info 0:0:0, and specify -module.Dan Winship2002-04-021-1/+1
| | | | | | | | | | | | | | | | | | | | | * providers/imap/Makefile.am (libcamelimap_la_LDFLAGS): Use -avoid-version instead of -version-info 0:0:0, and specify -module. (From Max Horn <max@quendi.de>). * providers/local/Makefile.am (libcamellocal_la_LDFLAGS): Likewise. * providers/nntp/Makefile.am (libcamelnntp_la_LDFLAGS): Likewise. * providers/sendmail/Makefile.am (libcamelsendmail_la_LDFLAGS): Likewise. * providers/smtp/Makefile.am (libcamelsmtp_la_LDFLAGS): Likewise. * providers/pop3/Makefile.am (libcamelpop3_la_LDFLAGS): Likewise. Also remove $(KRB4_LDFLAGS) since KPOP is gone. (INCLUDES): and $(KRB4_CFLAGS) svn path=/trunk/; revision=16305
* When we add a new name, up all of the cache limits, because we're probablyNot Zed2002-03-2519-58/+120
| | | | | | | | | | | | | | | | | | | 2002-03-25 Not Zed <NotZed@Ximian.com> * camel-text-index.c (text_index_add_name): When we add a new name, up all of the cache limits, because we're probably going to be adding more. (text_index_sync): Drop the cache limits back down again, we dont need them when looking words up. ** MERGE camel_index branch. * camel-text-index.[ch]: Added files i forgot to add (eep nearly lost all this work!) * camel-block-file.c (sync_nolock): Fix an infinite loop in syncing. svn path=/trunk/; revision=16242
* The day number has to be 2 chars wide, space filled to work properly withNot Zed2002-02-0810-15/+491
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-02-08 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-summary.c (camel_spool_summary_build_from): The day number has to be 2 chars wide, space filled to work properly with pine, etc. * providers/local/camel-spoold-store.[ch]: new type of provider 'spool directory', which lets you view external mbox dirs without adding any extra cruft. Perhaps it should use . files to store summaries? Still a bit experimental, there's a warning when you select it in the account editor. Finished off most of #1185. Can't rename or move folders. * camel-mime-utils.c (header_decode_date): If the date is 100->1900 then we actually want to use it as the year in the tm struct, not year+100. e.g. year 102 -> 2002, not 2102. 2002-02-07 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (get_folder): Pass path into spool_folder_new. * providers/local/camel-spool-folder.c (camel_spool_folder_new): (camel_spool_folder_construct): Take the full path to the folder and use that as the file path, independent of the full_name we use. 2002-02-07 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-provider.c: Added new type, spoold provider, spoold: for local directories. * providers/imap/camel-imap-store.c (get_one_folder_offline): Create offline uri's in a compatible manner to online ones. svn path=/trunk/; revision=15606
* If PATH_MAX doesn't exist, use _POSIX_PATH_MAX.Jeffrey Stedfast2002-01-111-0/+8
| | | | | | | | | 2002-01-10 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-folder.c: If PATH_MAX doesn't exist, use _POSIX_PATH_MAX. svn path=/trunk/; revision=15291
* If the mbox file is a symlink, follow the symlink and get the One TrueJeffrey Stedfast2002-01-101-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-01-09 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-folder.c (camel_mbox_folder_new): If the mbox file is a symlink, follow the symlink and get the One True Path so that we can rewrite the mbox later without worrying about clobbering the symlink. 2002-01-08 Jeffrey Stedfast <fejj@ximian.com> * camel-filter-search.c (TODO): There are a few sexp callbacks that could be modified to use fms->info rather than using a message object (like date and possibly mlist stuff) but *only* if the date exists on the CamelMessageInfo object (since it may be blank except for message flags). (camel_filter_search_get_message): New internal convenience function to make sure that the FilterMessageSearch has loaded the message (and to load the message if this isn't the case). (check_header): Call camel_filter_search_get_message(). (header_exists): Same. (header_regex): Here too. (header_full_regex): And here. (body_contains): Again here. (body_regex): Here too. (get_sent_date): Here also. (get_received_date): Same. (get_source): Here if we need to. (camel_filter_search_match): Now takes a callback function/data pair for on-demand message loading so that we don't necessarily have to load the message if the defined filter rules don't require it. * camel-filter-driver.c (camel_filter_driver_filter_folder): Don't bother fetching the message here, let camel_filter_driver_filter_message() worry about this. (get_message_cb): New utility callback to fetch a message. (camel_filter_driver_filter_message): Only fetch the message if we absolutely need it to get a CamelMessageInfo. Instead of passing a message object to camel_filter_search_match(), pass get_message_cb and some user_data so that the matching code can fetch the message on demand. svn path=/trunk/; revision=15276
* only use major and minor version in the camel providerdir, not micro and nanoDan Winship2001-12-181-4/+2
| | | | svn path=/trunk/; revision=15121
* Same as below.12001-11-013-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-10-31 <NotZed@Ximian.com> * providers/local/camel-spool-folder.c (spool_get_message): Same as below. * providers/local/camel-maildir-folder.c (maildir_get_message): Same as below. * providers/local/camel-mbox-folder.c (mbox_get_message): Set USER_CANCEL if failed due to EINTR. * camel-filter-driver.c (camel_filter_driver_filter_mbox): If construct from parser fails due to user cancel, set USER_CANCEL on exception. * camel-mime-part.c (construct_from_parser): Return error if the parser had an io error. * camel-mime-message.c (construct_from_parser): Check error on parser/return error. * camel-mime-parser.c (folder_scan_init): Init error number. (camel_mime_parser_errno): New function, return errno of any io failures. (folder_read): Set errno if a failure occured. (folder_seek): Same. (folder_scan_init_with_fd): Setup errno depeding on ok/failure. (folder_scan_init_with_stream): Same. svn path=/trunk/; revision=14559
* Remove the X-Evolution header before anyone else gets to see this private02001-10-301-0/+2
| | | | | | | | | | | 2001-10-30 <NotZed@Ximian.com> * providers/local/camel-mbox-folder.c (mbox_get_message): Remove the X-Evolution header before anyone else gets to see this private thing. Shoudl fix 11676 since we were inheriting flags from X-Evolution headers we didn't want to. svn path=/trunk/; revision=14453
* Dont try to move ibex if we have none.02001-10-301-4/+7
| | | | | | | | | 2001-10-30 <NotZed@Ximian.com> * providers/local/camel-local-store.c (rename_folder): Dont try to move ibex if we have none. svn path=/trunk/; revision=14429
* w(x) out some warnings.02001-10-301-1/+2
| | | | | | | | | | | | 2001-10-30 <NotZed@Ximian.com> * camel-mime-utils.c (header_decode_mailbox): w(x) out some warnings. * providers/local/camel-local-summary.c (camel_local_summary_load): Remove the warning about not loading summary file - its a valid case for new folders. svn path=/trunk/; revision=14411
* Changed to call ibex_move to rename it internally.82001-10-281-9/+44
| | | | | | | | | 2001-10-28 <NotZed@Ximian.com> * providers/local/camel-local-store.c (rename_folder): Changed to call ibex_move to rename it internally. svn path=/trunk/; revision=14294
* Use path not protocol as the path part of the uri of the folder_created82001-10-283-7/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-10-28 <NotZed@Ximian.com> * providers/local/camel-local-folder.c (camel_local_folder_construct): Use path not protocol as the path part of the uri of the folder_created event. * providers/local/camel-maildir-store.c (scan_dir): If FAST is set, dont try and scan for unread counts. * providers/local/camel-local-store.c (create_folder): Implement, just return the folderinfo of the folder matched, not all of it. * camel-store.c (camel_store_rename_folder): Rename the camelfolders before emitting the folderchanged event (otherwise vstore fails to pick up change. * camel-store.c (camel_store_init): Always use a default dir_sep of '/'. * camel-store.h (struct _CamelStore): Added a dir_sep to the base store so rename and whatnot can work, temporary fix for mixed dir separator in folder name api's. * providers/imap/camel-map-store.c: (imap_connect_online): Also set the store's dir_sep here. (imap_connect_offline): " svn path=/trunk/; revision=14275
* More fixing of the license texts.Ettore Perazzoli2001-10-2810-116/+110
| | | | svn path=/trunk/; revision=14217
* Fixing the license text.Ettore Perazzoli2001-10-2822-22/+0
| | | | svn path=/trunk/; revision=14212
* Finished implementation.72001-10-271-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-10-27 <NotZed@Ximian.com> * providers/imap/camel-imap-store.c (rename_folder): Finished implementation. * providers/local/camel-local-folder.c (local_rename): Implement local rename of folder objects. 2001-10-26 <NotZed@Ximian.com> * camel-vee-folder.c (camel_vee_folder_class_init): Hook into rename function. (vee_rename): Implement the veefolder rename function. (camel_vee_folder_class_init): (folder_changed_change): Kill a warning with a cast. * camel-vee-store.c (vee_rename_folder): Emit a folder_renamed event properly, also call parent to do some rename stuff. * camel-store.h: Added a CamelRenameInfo for the rename event. * camel-folder.c (camel_folder_rename): New function to rename a folder object. (camel_folder_class_init): Added a renamed event. (folder_rename): Default impl, set full_name, and set name assuming the dir separator is '/'. * camel-store.c (camel_store_class_init): Added folder_renamed event. (camel_store_rename_folder): Rename an active folder object if we have one, and update the folder table. (rename_folder): Make a default implementation that handles updating the folder tree. svn path=/trunk/; revision=14204
* Update the licensing information to require version 2 of the GPLEttore Perazzoli2001-10-2722-44/+44
| | | | | | (instead of version 2 or any later version). svn path=/trunk/; revision=14190
* made d(x) x recompile again.32001-10-231-5/+5
| | | | | | | | 2001-10-23 <NotZed@Ximian.com> * providers/local/camel-mbox-summary.c: made d(x) x recompile again. svn path=/trunk/; revision=13932
* No, use Storing, as the other code does :p (spool_summary_check): Check22001-10-231-3/+3
| | | | | | | | | | 2001-10-22 <NotZed@Ximian.com> * providers/local/camel-spool-summary.c (summary_rebuild): No, use Storing, as the other code does :p (spool_summary_check): Check for consistency. svn path=/trunk/; revision=13904
* s/summarising/summarizing/. (spool_summary_check): s/summarise/summarize/.Jon Trowbridge2001-10-231-3/+3
| | | | | | | | | | 2001-10-22 Jon Trowbridge <trow@ximian.com> * providers/local/camel-spool-summary.c (summary_rebuild): s/summarising/summarizing/. (spool_summary_check): s/summarise/summarize/. svn path=/trunk/; revision=13902
* Added CAMEL_CFLAGS so we get the right iconv stuff, patch from Yanko82001-10-191-0/+1
| | | | | | | | | | 2001-10-18 <NotZed@Ximian.com> * providers/(imap|local|pop3|sendmail|smtp)/Makefile.am: Added CAMEL_CFLAGS so we get the right iconv stuff, patch from Yanko Kaneti <yaneti@declera.com> svn path=/trunk/; revision=13783
* String cleanup for bug #6640.Jeffrey Stedfast2001-10-191-2/+2
| | | | | | | | | 2001-10-18 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c: String cleanup for bug #6640. svn path=/trunk/; revision=13777
* Use '.' as the inbox name for filter new messages test.72001-10-181-1/+1
| | | | | | | | | | 2001-10-17 <NotZed@Ximian.com> * providers/local/camel-maildir-folder.c (camel_maildir_folder_new): Use '.' as the inbox name for filter new messages test. svn path=/trunk/; revision=13742
* Same as maildir and mbox append-message.Jeffrey Stedfast2001-10-182-6/+14
| | | | | | | | | | | | | | | | | | | | | | | 2001-10-17 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mh-folder.c (mh_append_message): Same as maildir and mbox append-message. * providers/local/camel-maildir-folder.c (maildir_append_message): Same as mbox append. * camel-exception.c (camel_exception_set): Make sure the new description isn't the same as the old description pointer before freeing the old one. (camel_exception_setv): Don't free the old description until we set the new one this way we can reuse the old description in the new description. * providers/local/camel-mbox-folder.c (mbox_append_message): If errno == EINTR, then we got a user-cancel so set the exception appropriately so that we don't make the user shit his pants. svn path=/trunk/; revision=13739
* Make sure the new description isn't the same as the old descriptionJeffrey Stedfast2001-10-181-4/+8
| | | | | | | | | | | | | | | | | 2001-10-17 Jeffrey Stedfast <fejj@ximian.com> * camel-exception.c (camel_exception_set): Make sure the new description isn't the same as the old description pointer before freeing the old one. (camel_exception_setv): Don't free the old description until we set the new one this way we can reuse the old description in the new description. * providers/local/camel-mbox-folder.c (mbox_append_message): If errno == EINTR, then we got a user-cancel so set the exception appropriately so that we don't make the user shit his pants. svn path=/trunk/; revision=13737
* Patch from Danw, Use unread count of -1 to mark unflagged messages. Make72001-10-181-5/+6
| | | | | | | | | | | | | | | 2001-10-17 <NotZed@Ximian.com> * providers/imap/camel-imap-store.c (get_folder_info_online): (parse_list_response_as_folder_info): Patch from Danw, Use unread count of -1 to mark unflagged messages. Make sure any folder we dont lookup explicitly is marked as -1. Should fix #9947 and friends. * providers/local/camel-mbox-summary.c (mbox_summary_sync): Only touch the summary if the timestamp or size changed. svn path=/trunk/; revision=13731
* oops, we want get_unread_message_count, not get_message_count!02001-10-111-1/+1
| | | | | | | | | | | | | | 2001-10-10 <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (scan_dir): oops, we want get_unread_message_count, not get_message_count! 2001-10-09 <NotZed@Ximian.com> * camel-service.c (camel_service_disconnect): Duplicate connect code that unregisters a cancel op if we created one. svn path=/trunk/; revision=13561
* Implement.92001-10-102-0/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-10-09 <NotZed@Ximian.com> * providers/local/camel-spool-folder.c (spool_search_by_uids): Implement. * providers/imap/camel-imap-search.c (imap_body_contains): If searching a sub-set of the total message count, then use a UID range to search only specific messages. * camel-vee-folder.c (vee_folder_change_match): Removed. (folder_changed_add_uid): Helper func for changed code. (folder_changed_remove_uid): " (folder_changed_change_uid): " (folder_changed): Rewritten. Supports proper auto-updating of changes, but not removals till a sync occurs. (vee_search_by_uids): Implement. (folder_changed): Changed to call an async threaded function to do the actual folder updating. * camel-folder-summary.c (camel_flag_list_copy): New func to copy a whole list of flags. (camel_tag_list_copy): New func to copy a whole list of flags. * providers/imap/camel-imap-folder.c (imap_search_by_uids): Implement. * providers/local/camel-local-folder.c (local_search_by_uids): Implement. * camel-folder.c (camel_folder_search_by_uids): New function, search a subset of uid's. (search_by_uids): Default impl, return error. svn path=/trunk/; revision=13532
* replace the ever-growing list of gbooleans with a single guint32 forDan Winship2001-10-093-6/+6
| | | | | | | | | | | | | | | | | | | | | | * camel-folder.h (struct _CamelFolder): replace the ever-growing list of gbooleans with a single guint32 for flags. * camel-folder.c: Update folder flag setting/checking. * providers/pop3/camel-pop3-folder.c (camel_pop3_folder_init): * providers/nntp/camel-nntp-folder.c (camel_nntp_folder_new): * providers/local/camel-spool-folder.c (spool_init, camel_spool_folder_new): * providers/local/camel-maildir-folder.c (camel_maildir_folder_new): * providers/local/camel-local-folder.c (local_init): * providers/imap/camel-imap-folder.c (camel_imap_folder_init, camel_imap_folder_new): * camel-vtrash-folder.c (camel_vtrash_folder_init): * camel-vee-folder.c (camel_vee_folder_init): * camel-digest-folder.c (camel_digest_folder_init): update folder flag setting. svn path=/trunk/; revision=13509
* Dont explicitly save metadata, its saved in summary_sync.32001-10-045-50/+24
| | | | | | | | | | | | | | | | | | | | | | | | | 2001-10-03 <NotZed@Ximian.com> * providers/local/camel-local-folder.c (local_sync): Dont explicitly save metadata, its saved in summary_sync. * providers/local/camel-mh-summary.c: Call superclass. (mh_summary_check): Dont save ibex. * providers/local/camel-maildir-summary.c: Call superclass method. (maildir_summary_check): Dont save ibex explictly. * providers/local/camel-mbox-summary.c: Call super-class sync when done, saves summary/ibex, etc. (mbox_summary_check): Dont save ibex. (mbox_summary_sync): Call summary_check rather than trying to update from our known position. * providers/local/camel-local-summary.c (camel_local_summary_check): Dont save the summary or index here. (local_summary_sync): Save the summary/index here. svn path=/trunk/; revision=13397
* Strange are the ways of alloca. Fixes 11543.Dan Winship2001-10-031-1/+4
| | | | | | | * providers/local/camel-local-provider.c (local_url_equal): Strange are the ways of alloca. Fixes 11543. svn path=/trunk/; revision=13375
* for hashing/comparing local url's, we ignore trailing /'s in paths (maybe22001-10-031-12/+94
| | | | | | | | | | | 2001-10-02 <NotZed@Ximian.com> * providers/local/camel-local-provider.c (local_url_hash, local_url_equal): for hashing/comparing local url's, we ignore trailing /'s in paths (maybe shuld handle multiple /'s too). (camel_provider_module_init): Use local_url_hash/equal for all functions. svn path=/trunk/; revision=13362
* Go back to using the store url's path, not the toplevel_dir thing.22001-10-031-1/+1
| | | | | | | | | | | | 2001-10-02 <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (get_folder_info): Go back to using the store url's path, not the toplevel_dir thing. * camel-operation.c (camel_operation_progress): Fix the progress logic, so we dont update too often. svn path=/trunk/; revision=13354
* Fix up the provider flags to specify things more completely so we don'tDan Winship2001-10-021-3/+4
| | | | | | | | | | | | | | * camel-provider.h: Fix up the provider flags to specify things more completely so we don't have to hardcode provider names in the mailer. * providers/local/camel-local-provider.c: MH, mbox, and Maildir are LOCAL. MH and mbox are no longer STORAGE by the new definition. * camel-session.c (vee_provider): The vfolder store is a STORAGE. svn path=/trunk/; revision=13276
* Don't munge the URL; CamelSession's caching relies on it not changing.Dan Winship2001-10-026-42/+33
| | | | | | | | | | | | | | | | | | | | * providers/local/camel-local-store.c (construct): Don't munge the URL; CamelSession's caching relies on it not changing. Instead, add a toplevel_dir field to CamelLocalStore, and set that to the path, but always ending with /. (camel_local_store_finalize): Free toplevel_dir (camel_local_store_get_toplevel_dir): Return toplevel_dir rather than url->path. * providers/local/*: Lots of s/url->path/toplevel_dir/ * providers/local/camel-spool-store.c (construct): Likewise, don't try to strip a trailing / from url->path here, but I didn't make the corresponding toplevel_dir change, because there's no good reason someone should expect "/var/spool/mail/danw/" to work since that's not a directory. svn path=/trunk/; revision=13264
* Init the nntp url hash and url_equal functions.Jeffrey Stedfast2001-09-291-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-09-28 Jeffrey Stedfast <fejj@ximian.com> * providers/nntp/camel-nntp-provider.c (camel_provider_module_init): Init the nntp url hash and url_equal functions. * providers/sendmail/camel-sendmail-provider.c (camel_provider_module_init): Init the sendmail url hash and url_equal functions. * providers/smtp/camel-smtp-provider.c (camel_provider_module_init): Init the smtp url hash and url_equal functions. * providers/pop3/camel-pop3-provider.c (camel_provider_module_init): Init the pop3 url hash and url_equal functions. * providers/imap/camel-imap-provider.c (camel_provider_module_init): Init the imap url hash and url_equal functions. * providers/local/camel-local-provider.c (camel_provider_module_init): Init the local url hash and url_equal functions. * camel-session.c (camel_session_class_init): Init the vfolder url hash and url_equal functions. * camel-provider.h: Added url_hash and url_equal function pointers to the structure. * camel-vtrash-folder.c (vtrash_move_messages_to): Oops, a CamelFolder is not a CamelFolderClass. svn path=/trunk/; revision=13237
* New function to just load the summary. Not much use yet, until unreadMichael Zucci2001-09-211-0/+29
| | | | | | | | | | | | | | | | | | | | | * camel-folder-summary.c (camel_folder_summary_header_load): New function to just load the summary. Not much use yet, until unread counts are stored in the summary (which now looks like too much work!). * camel-mime-utils.c (header_decode_mailbox): Crappy fix for stupid mailers. If we get 'name b. name <foo>' then treat it as '"name b. name" <foo>'. See 8147. (header_decode_mailbox): Another fix for really broken mailers that have things that look like addresses followed by <address> bits. (rfc2047_encode_word): Escape ??= to avoid some bizarre warning about trigraphs. (scan_dir): If we dont have the folder open, then scan the 'new' and 'cur' folders for new and unread messages to count instead. svn path=/trunk/; revision=13040
* Setup unread count properly, and also setup the url properly.Michael Zucci2001-09-212-12/+28
| | | | | | | | | | | | * providers/local/camel-local-folder.c (camel_local_folder_construct): Setup unread count properly, and also setup the url properly. (scan_dir): Dont include empty host part in url for folder. (scan_dir): Lookup folder counts for any folders we currenty have open. svn path=/trunk/; revision=13035
* Build the path on the folderinfo.02001-09-215-12/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-09-20 <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (camel_folder_info_new): Build the path on the folderinfo. * providers/local/camel-spool-store.c (get_folder_info): If we have this folder open, then set unread from the folder itself. (get_folder_info): Change the INBOX path to not include the leading /. * providers/local/camel-spool-folder.c (camel_spool_folder_construct): Fix path. (camel_spool_folder_construct): Properly setup the url field when we say we've got a new folder created. * providers/imap/camel-imap-store.c (unsubscribe_folder): Build path on folderinfo. * camel-store.c (camel_folder_info_build_path): Prepend / to path. * camel-vee-folder.c (camel_vee_folder_construct): Use macro for unmatched folder name. (camel_vee_folder_new): " * camel-vee-store.c (vee_get_folder_info): Use macro for unmatched folder name. (vee_delete_folder): " (vee_rename_folder): " (vee_get_folder): Prepend / onto path. (vee_delete_folder): Setup path in folderinfo. (vee_get_folder_info): Fix path in folderinfo. * camel-vee-folder.h (CAMEL_UNMATCHED_NAME): New define for unmatched (internal) name. svn path=/trunk/; revision=13022
* And finally here.Jeffrey Stedfast2001-09-212-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | 2001-09-20 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-spool-folder.c (camel_spool_folder_construct): And finally here. * providers/local/camel-local-folder.c (camel_local_folder_construct): And here. * camel-vee-store.c (vee_get_folder): ANd here too. (vee_get_folder_info): And here. * providers/imap/camel-imap-store.c (create_folder): Use camel_folder_info_build() and do better error checking. (subscribe_folder): Set the path on the folder info. * camel-store.c (camel_folder_info_build): Set the folder-info path if it hasn't already been set by the caller. (camel_folder_info_free): Free the path. * camel-store.h: Added a path member to the FolderInfo type. svn path=/trunk/; revision=13019
* General cleanup of camel debug printfs.92001-09-195-10/+12
| | | | | | | | | | | | | | | | | 2001-09-19 <NotZed@Ximian.com> * General cleanup of camel debug printfs. * camel-lock.c (camel_lock_fcntl): Changed to return 'success' if the error indicates file locking isn't supported on this filesystem. Still return a warning just incase (if its the first time). Might fix a lot of reported bugs. * providers/local/camel-spool-store.c (get_folder_info): Dont include the empty // host part in the uri. This 'breaks' the service lookup. svn path=/trunk/; revision=12973
* If filter inbox is set on the store, and we're opening inbox '', then82001-09-1910-22/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-09-18 <NotZed@Ximian.com> * providers/local/camel-maildir-folder.c (camel_maildir_folder_new): If filter inbox is set on the store, and we're opening inbox '', then enable filtering on new messages. * providers/local/camel-local-folder.c (camel_local_folder_construct): After loading the summary, check it, and only abort if that fails. Also maintain the changes count. * providers/local/camel-local-summary.c (camel_local_summary_load): Remove summary_check code from here. (camel_local_summary_check): Sync index/summary here, if we were successful. * providers/local/camel-spool-folder.c (camel_spool_folder_new): If we have filter-new-messages-on-inbox set and we just opened inbox, turn on filtering on this folder. (camel_spool_folder_construct): Keep track of changes for the folder, so that filter-new-messages works right (?) * providers/local/camel-spool-store.c (get_folder): Pass 'INBOX' as the folder name, not the path. * camel-folder-search.c (search_not): Modified patch from <peterw@ximian.com> since the summary is messageinfo's, not strings. ** Ok so the problem with the stuff below is that maildir/spool 'summary_load' throws away all events, including recents, joy eh? * providers/local/camel-maildir-summary.c (maildir_summary_check): Add new messages to the recent changeinfo. * providers/local/camel-spool-summary.c: Mark 'new' message as recent, for later processing if required (i.e. 'filter new messages'). * camel-store.c (construct): new function, cascade up construct method and check for 'filter' param, and set accordingly for any one that might want it. * providers/imap/camel-imap-store.c (construct): map the param_filter_inbox flag to the store->flags as CAMEL_STORE_FILTER_INBOX. * camel-store.h (CAMEL_STORE_FILTER_INBOX): new flag to tell it to filter inbox. * providers/imap/camel-imap-folder.h: Removed do_filtering flag from CamelImapFolder. * providers/imap/camel-imap-folder.c (imap_update_summary): Remove the 'recents' parameter, use the 'changes' parameter instead to convey this info. (camel_imap_folder_changed): Changed for update_summary api change. Now always just emit the changed event if we have any changes to report, filtering code removed, handled upstream. (filter_proc): (filter_free): Removed old filtering code. (camel_imap_folder_new): Set the filter_recent flag on the folder if we're the inbox and filtering of inbox is enabled. * camel-folder.c (folder_changed): If we have 'recent' messages, and are set to filter recents, then freeze the folder and launch a thread to do the processing (or similar if threading not enabled). (thaw): Make sure we emit the changed signal outside of owning the lock and if things have changed. Also, no longer bother downgrading folder_changed events to message_changed events. * camel-folder.h (struct _CamelFolder): Added filter_recent flag -> signifies all recent messages in folder should be filtered. * camel-session.c: (camel_session_thread_msg_new, camel_session_thread_msg_free, camel_session_thread_queue, camel_session_thread_wait): code to handle async operations as part of camel processing. (camel_session_finalise): free thread_lock, destroy thread, active hash, etc. (camel_session_init): init thread, active hash, etc. (camel_session_class_init): Init virtual functions. (session_thread_msg_new, session_thread_msg_free, session_thread_destroy, session_thread_received, session_thread_queue, session_thread_wait): default implementation of session threads stuff. 2001-09-17 <NotZed@Ximian.com> * camel-folder.c (camel_folder_change_info_recent_uid): New function to add a 'recent' uid to the change info. (camel_folder_change_info_clear): Clear recent list. (camel_folder_change_info_free): Free recent list. (camel_folder_change_info_new): Setup recent list. * camel-folder.h: Added a uid_recent item to the folder_changed event data. * providers/local/camel-maildir-store.c (scan_dir): Free new in the right block. * providers/local/camel-local-provider.c: Add local config entries to filter on new messages in spool and maildir provider. * camel-vee-folder.c (vee_folder_construct): Remove the assertion which stops ? in names from being allowed. svn path=/trunk/; revision=12956
* Do error-checking based on function return values rather than exceptionsJeffrey Stedfast2001-09-141-7/+7
| | | | | | | | | | | 2001-09-13 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-folder.c (mbox_append_message): Do error-checking based on function return values rather than exceptions as it's possible for them to be NULL. (mbox_get_message): Same. svn path=/trunk/; revision=12814
* Pass in a hashtalbe used for finding visited nodes. (inode_hash):02001-09-111-26/+69
| | | | | | | | | | | | | | | | | 2001-09-10 <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (get_folder_info): Pass in a hashtalbe used for finding visited nodes. (inode_hash): (inode_equal): (inode_free): Helper functions for visited node checks, hashes on inode + device number. (scan_dir): Dont re-visited directories we've already visited, use inodes + device number. Also, if the folder doesn't contain cur/tmp/new, mark it as noselect, but continue to recurse folders, if asked. svn path=/trunk/; revision=12760
* Progress reporting while moving messages.02001-09-111-4/+4
| | | | | | | | | | | | | | | 2001-09-10 <NotZed@Ximian.com> * camel-folder.c (move_messages_to): Progress reporting while moving messages. * camel-store.c (camel_store_delete_folder): Make sure we remove the folder from our vtrash, if we have it in our opened set, and also remove it from our hashtable. (camel_store_rename_folder): Remove the old folder name from the folder cahce, if it is there. svn path=/trunk/; revision=12758
* Likewise.Not Zed2001-09-082-8/+8
| | | | | | | | | | | | | | | 2001-09-08 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-summary.c (spool_summary_sync_full): Likewise. * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): Fix the wording. * camel-tcp-stream-raw.c (stream_read): Save errno around fcntl call in cancellable read case. Also, loop while we get EINTR. This might fix some weird reconnect behaviour with pop. (stream_write): " svn path=/trunk/; revision=12700
* s/Synchronising/Synchronizing/. (mbox_summary_sync_quick): Likewise.Ettore Perazzoli2001-09-081-4/+4
| | | | | | | | | * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): s/Synchronising/Synchronizing/. (mbox_summary_sync_quick): Likewise. (summary_rebuild): s/Summarising/Summarizing/. svn path=/trunk/; revision=12683
* Return the default folder (ie. INBOX) rather than saying we don't supportJeffrey Stedfast2001-08-311-3/+1
| | | | | | | | | | 2001-08-30 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-spool-store.c (get_inbox): Return the default folder (ie. INBOX) rather than saying we don't support an inbox. svn path=/trunk/; revision=12535
* Changed the description/names of some of the local providers to try andJeffrey Stedfast2001-08-281-6/+6
| | | | | | | | | | | | | | | 2001-08-27 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c: Changed the description/names of some of the local providers to try and clarify the meanings. * providers/pop3/camel-pop3-provider.c: Simplify the POP description - we want short but sweet. * providers/imap/camel-imap-provider.c: s/IMAPv4/IMAP svn path=/trunk/; revision=12486
* ["Summarising" and "Synchronising" are spelt with a "s" in ENGLISH]Not Zed2001-08-252-8/+8
| | | | | | | | | | | | | | | 2001-08-25 Not Zed <NotZed@Ximian.com> ["Summarising" and "Synchronising" are spelt with a "s" in ENGLISH] * providers/local/camel-mbox-summary.c (mbox_summary_sync_quick): s/Synchronizing/Synchronising/. * providers/local/camel-mbox-summary.c (summary_rebuild): s/Summarizing/Summarising/ svn path=/trunk/; revision=12470
* Revert Not Zed's previous commits as they apparently can cause seriousPeter Williams2001-08-252-5/+5
| | | | | | | | | 2001-08-24 Peter Williams <peterw@ximian.com> * Revert Not Zed's previous commits as they apparently can cause serious data loss for POP3 users. svn path=/trunk/; revision=12461
* s/Synchronising/Synchronizing/.Ettore Perazzoli2001-08-251-3/+3
| | | | | | | | | | * providers/local/camel-mbox-summary.c (mbox_summary_sync_quick): s/Synchronising/Synchronizing/. * providers/local/camel-mbox-summary.c (summary_rebuild): s/Summarising/Summarizing/ svn path=/trunk/; revision=12444
* Likewise.Not Zed2001-08-242-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-08-24 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-summary.c (summary_rebuild): Likewise. * providers/local/camel-mbox-summary.c (summary_rebuild): Summarising is spelt with an s. 2001-08-23 Not Zed <NotZed@Ximian.com> * camel-mime-part.c (write_to_stream): If we have rawtext, then dont do any charset conversion, only encoding/crlf conversion. * camel-data-wrapper.h (struct _CamelDataWrapper): Added 'rawtext' member, says the character encoding is raw, not utf8. * providers/local/camel-spool-summary.c (spool_summary_sync_quick): Synchronising is spelt with an s, not a z. (spool_summary_sync_full): " * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): No, synchronising is spelt with an s. (mbox_summary_sync_quick): " * camel-mime-part-utils.c (camel_mime_part_construct_content_from_parser): Remove the warnings which aren't going anywhere fast. (convert_buffer): Function to convert a bytearray of textual content from one charset to another. If the charset doesn't exist or fails, then do no conversion. (simple_data_wrapper_construct_from_parser): First, read in data, then try and convert it using the specified charset if supplied. If that fails, then dont do any conversion, and leave as raw. Also, if we have any x-* charsets, then dont do any processing. svn path=/trunk/; revision=12429
* Add a missing \n to the end of a printf.Peter Williams2001-08-242-2/+2
| | | | | | | | | | | 2001-08-23 Peter Williams <peterw@ximian.com> * providers/local/camel-mbox-summary.c (summary_rebuild): Add a missing \n to the end of a printf. * providers/local/camel-spool-summary.c (summary_rebuild): Same. svn path=/trunk/; revision=12421
* s/Synchronising/Synchronizing/. (mbox_summary_sync_quick): Likewise.Ettore Perazzoli2001-08-202-4/+4
| | | | | | | | | | | * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): s/Synchronising/Synchronizing/. (mbox_summary_sync_quick): Likewise. * providers/local/camel-spool-summary.c (spool_summary_sync_full): Likewise. (spool_summary_sync_quick): Likewise. svn path=/trunk/; revision=12269
* s/summarising/summarizing/. (summary_rebuild): Likewise.Ettore Perazzoli2001-08-122-7/+7
| | | | | | | | | | | | | | * providers/local/camel-spool-summary.c (summary_rebuild): s/summarising/summarizing/. (summary_rebuild): Likewise. * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): s/summarise/summarize/. (mbox_summary_sync_quick): Likewise. (summary_rebuild): Likewise. (mbox_summary_check): Likewise. svn path=/trunk/; revision=11919
* If we fail to get the lock, make sure we close our locking fd, and resetNot Zed2001-08-011-1/+7
| | | | | | | | | | 2001-08-01 Not Zed <NotZed@Ximian.com> * providers/local/camel-mbox-folder.c (mbox_lock): If we fail to get the lock, make sure we close our locking fd, and reset it. Fixes the crash part of 5095. svn path=/trunk/; revision=11538
* Added some operation progress reporting. Actual data transfer is 'tricky'Not Zed2001-07-231-6/+1
| | | | | | | | | | | | | | | | | | | | 2001-07-23 Not Zed <NotZed@Ximian.com> * providers/smtp/camel-smtp-transport.c (smtp_auth, smtp_helo, send_to): Added some operation progress reporting. Actual data transfer is 'tricky' because of the layers used. (smtp_auth): Instead of checking exception_is_set, use challenge==NULL to test if sasl_challenge_base64 failed. * providers/local/camel-mbox-summary.c (mbox_summary_sync): Remove peters changes below and put in a better fix. These functions already return -1 on error, just use that, and not worry about building our own exception redundantly. * camel-service.c (camel_get_host_byname): Turn the progress into a transient event. svn path=/trunk/; revision=11301
* More usage fixes for CamelException. Check our own exception forPeter Williams2001-07-211-2/+6
| | | | | | | | | | 2001-07-20 Peter Williams <peterw@ximian.com> * providers/local/camel-mbox-summary.c (mbox_summary_sync): More usage fixes for CamelException. Check our own exception for summary_update and xfer it out if an error occurred. svn path=/trunk/; revision=11273
* Removed some code i wasn't supposed to commit.Not Zed2001-07-121-2/+14
| | | | | | | | | | | | | | | 2001-07-12 Not Zed <NotZed@Ximian.com> * camel-folder-summary.c (camel_folder_summary_info_new_from_message): Removed some code i wasn't supposed to commit. * providers/local/camel-local-summary.c (local_summary_add): Only set info->size if it is not zero. (local_summary_add): If we dont get a size from the info passed in, calculate it using a null stream write. Should do #4392. svn path=/trunk/; revision=11025
* Create the messageinfo itself, so we can properly set the size.Not Zed2001-07-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | 2001-07-11 Not Zed <NotZed@Ximian.com> * camel-filter-driver.c (camel_filter_driver_filter_mbox): Create the messageinfo itself, so we can properly set the size. * camel-movemail.c (camel_movemail_solaris): Write out the from line between each message. 2001-07-10 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-summary.c (local_summary_add): Copy the size across from the source message info if supplied. * camel-stream-null.c: Added a 'written' member which keeps track of how much has been written to the stream. * camel-movemail.c (camel_movemail): If we have BROKEN_SPOOL defined, then use the solaris movemail to quote from lines that sendmail didn't. (camel_movemail_solaris): Compile this in if BROKEN_SPOOL defined. svn path=/trunk/; revision=10989
* Oops, e_poolv_set free's it for us, so dont double-free here.Not Zed2001-07-091-1/+0
| | | | | | | | | 2001-07-09 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-summary.c (maildir_summary_sync): Oops, e_poolv_set free's it for us, so dont double-free here. svn path=/trunk/; revision=10902
* Fixes bug #1138.Jeffrey Stedfast2001-07-071-0/+9
| | | | | | | | | 2001-07-06 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-maildir-store.c (get_inbox): Fixes bug #1138. svn path=/trunk/; revision=10860
* Make the `day-of-month' digit take up 2 chars by using "%2d". Fixes bugJeffrey Stedfast2001-07-071-1/+1
| | | | | | | | | | | 2001-07-06 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-summary.c (camel_mbox_summary_build_from): Make the `day-of-month' digit take up 2 chars by using "%2d". Fixes bug #3989 for lame mailers like Pine. svn path=/trunk/; revision=10858
* When indexing a new record, create a pseudo word 'ibexindexed' so we canNot Zed2001-07-051-19/+17
| | | | | | | | | | | | | | | | | | | | | | | 2001-07-05 Not Zed <NotZed@Ximian.com> * camel-folder-summary.c (camel_folder_summary_info_new_from_message): When indexing a new record, create a pseudo word 'ibexindexed' so we can always tell that a message has already been idnexed, even if it contains no words of its own. Things like maildir use this check to see if its already been processed, and it matters if it is incorrect in this case (not just wasted cycles). (camel_folder_summary_info_new_from_parser): And same here. * providers/local/camel-maildir-summary.c (maildir_summary_sync): Changed the logicfor epoolv code to be different, we dont need to update hash references or any tricky stuff. (maildir_summary_check): Samehere. * camel-folder-summary.h: Removed include of e-memory.h. svn path=/trunk/; revision=10785
* Update the copyrights, replacing Helix Code with Ximian andEttore Perazzoli2001-06-2332-53/+53
| | | | | | helixcode.com with ximian.com all over the place. svn path=/trunk/; revision=10440
* Only create a missing uid if we have indexing turned on.Not Zed2001-06-186-44/+238
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-06-18 Not Zed <NotZed@Ximian.com> * camel-folder-summary.c (camel_folder_summary_info_new_from_parser): Only create a missing uid if we have indexing turned on. * camel-lock-helper.c (setup_process): Function to setup process/sanity/security checks. Change to the real uid as soon as we can. (lock_path): First try to lock as the real uid, if that fails, try the root uid. (unlock_id): Unlock as the uid we created the lock as. * Makefile.am (INCLUDES): Added -DCAMEL_SBINDIR for lock helper location. * providers/local/camel-spool-folder.c (spool_lock): Implemented, using lock helper locking. Need to work out if the locking requires a root created lock? (spool_unlock): Likewise. 2001-06-15 Not Zed <NotZed@Ximian.com> * camel-lock-helper.c: Setuid Lock helper process. Creates and manages .locks, keeping them active, removing them, etc. What real perms it needs is a little system dependent. 2001-06-14 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-store.c (get_folder_info): Implement. (scan_dir): Does the work of scanning for maildir directories. 2001-06-13 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-store.c (get_folder_info): Implemented, just returns a hardcoded INBOX folder. (free_folder_info): implemented, free's the 1 possible level of folder info. * providers/local/camel-spool-folder.c (camel_spool_folder_construct): Set the real unread message count on the folder_created thing. svn path=/trunk/; revision=10261
* A new provider, for spool mailboxes. Mostly a cut and paste of the mboxNot Zed2001-06-1210-2/+2378
| | | | | | | | | | | | | | | | | | | | | | | | | 2001-06-12 Not Zed <NotZed@Ximian.com> * providers/local/camel-spool-*.[ch]: A new provider, for spool mailboxes. Mostly a cut and paste of the mbox code, but not a subclass CamelLocal*. Not tested a lot, doesn't lock yet, use with extreme caution. * tests/lib/folders.c (test_folder_message_ops): Added spool arg, spool folders can't be deleted, renamed, etc. (test_folder_basic): Same. * tests/folder/test2.c (main): Added checks for spool type. * tests/[message|stream|folder|misc|smime]/Makefile.am (LDADD): Added db3 flags, so make check compiles, doesn't run though. 2001-05-24 Not Zed <NotZed@Ximian.com> * providers/local/camel-local-provider.c (camel_provider_module_init): Added spool provider. svn path=/trunk/; revision=10198
* remove the summary info so we are not out-of-sync with the maildir folder.Jeffrey Stedfast2001-05-263-71/+88
| | | | | | | | | | | | | | | | 2001-05-25 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-maildir-folder.c (maildir_append_message): remove the summary info so we are not out-of-sync with the maildir folder. * providers/local/camel-mh-folder.c (mh_append_message): remove the summary info so we are not out-of-sync with the mh folder. * providers/local/camel-mbox-folder.c (mbox_append_message): remove the summary info so we are not out-of-sync with the mbox. svn path=/trunk/; revision=9996
* s/folder_deleted/folder_created - result of a bad copy/paste.Jeffrey Stedfast2001-05-241-1/+1
| | | | | | | | | | 2001-05-23 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-folder.c (camel_local_folder_construct): s/folder_deleted/folder_created - result of a bad copy/paste. svn path=/trunk/; revision=9957
* new abstract class for disconnectable remote storesDan Winship2001-05-041-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-disco-store.c: new abstract class for disconnectable remote stores * camel-disco-folder.c: new abstract class for folders on disconnectable stores. * Makefile.am: Add camel-disco-folder.[ch] and camel-disco-store.[ch]. * providers/imap/camel-imap-store.c: Make this a subclass of CamelDiscoStore, and fix up the offline interfaces for the changes since they were first written (particularly the fact that some IMAP stores don't just use subscribed folders). * providers/imap/camel-imap-folder.c: Make this a subclass of CamelDiscoFolder, although most ops still fail in disconnected mode. * camel-store.c (camel_store_get_folder_info): Change gboolean, gboolean, gboolean to guint32 in the prototype for this function. * providers/local/camel-local-store.c (get_folder_info): Update for prototype change. svn path=/trunk/; revision=9659
* New file, with the int, string, time_t, and off_t encode/decode routinesDan Winship2001-04-271-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | * camel-file-utils.c: New file, with the int, string, time_t, and off_t encode/decode routines from camel-folder-summary.c moved here and renamed, for the enjoyment of non-CamelFolderSummary subclasses. * Makefile.am (libcamel_la_SOURCES): Add camel-file-utils.c (libcamelinclude_HEADERS): and camel-file-utils.h * camel-folder-summary.c: Remove functions that were moved to camel-file-utils.c, update uses of them for the new names. (camel_folder_summary_{en,de}code_token are still here.) * providers/local/camel-mbox-summary.c: Use camel_file_util_* names * providers/imap/camel-imap-summary.c: Use camel_file_util_* names * providers/imap/camel-imap-store.c (imap_store_setup_online, imap_store_setup_offline): Use camel_file_util_* names, which makes much more sense since this isn't folder summary stuff. svn path=/trunk/; revision=9590
* Remove UNICODE_CFLAGS (and some other stuff that's redundant withDan Winship2001-04-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.am (INCLUDES): Remove UNICODE_CFLAGS (and some other stuff that's redundant with EXTRA_GNOME_CFLAGS) (libcamel_la_LIBADD): Replace UNICODE_LIBS with GAL_LIBS. * camel-search-private.c: * camel-pgp-context.c: * camel-mime-utils.c: Use gunicode interfaces rather than libunicode. * camel-charset-map.c: Use gunicode rather than libunicode. (The charmap-regen code still depends on libunicode though.) * camel-mime-filter-charset.h: * tests/message/test2.c (convert): Use iconv rather than unicode_iconv. * providers/smtp/Makefile.am (libcamelsmtp_la_LIBADD): * providers/pop3/Makefile.am (libcamelpop3_la_LIBADD): * providers/local/Makefile.am (libcamellocal_la_LIBADD): Remove UNICODE_LIBS. * camel.c (camel_init): Remove call to unicode_init. * camel-mime-parser.c: Remove unused unicode.h include. svn path=/trunk/; revision=9585
* Applied jacob's patches for e-poolv stuff.Not Zed2001-04-262-10/+18
| | | | | | | | 2001-04-26 Not Zed <NotZed@Ximian.com> * Applied jacob's patches for e-poolv stuff. svn path=/trunk/; revision=9571
* Don't we want to tell where we are by using the start of the message? IJeffrey Stedfast2001-04-171-5/+5
| | | | | | | | | | | | | 2001-04-16 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-mbox-summary.c (summary_rebuild): Don't we want to tell where we are by using the start of the message? I think this should be using camel_mime_parser_tell_start_from() instead. Also divide by the size *before* multiplying by 100 so that we don't overflow the int which was giving us negative values for our progress status (oops). svn path=/trunk/; revision=9394
* Check if gethostbyname_r take five paramsJP Rosevear2001-04-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-04-11 JP Rosevear <jpr@ximian.com> * configure.in: Check if gethostbyname_r take five params * acconfig.h: add GETHOSTBYNAME_R_FIVE_ARGS 2001-04-11 JP Rosevear <jpr@ximian.com> * providers/imap/Makefile.am: user GNOME_INCLUDEDIR since gnome files are included in the top level camel headers and the gtk include dir is now versioned and such * providers/local/Makefile.am: ditto * providers/pop3/Makefile.am: ditto * providers/smtp/Makefile.am: ditto * providers/sendmail/Makefile.am: ditto * camel-service.c: use five arg version of gethostbyname_r if appropriate (camel_get_host_byname): check if msg->herr is non-zero instead of checking if msg->hp is null since we may not always have msg->hp svn path=/trunk/; revision=9239
* merge from evolution-0-10-branch to evolution-0-10-merge-0Not Zed2001-04-051-0/+4
| | | | | | | | 2001-04-05 Not Zed <NotZed@Ximian.com> * merge from evolution-0-10-branch to evolution-0-10-merge-0 svn path=/trunk/; revision=9194
* Big header cleanups and nntp compile fixKjartan Maraas2001-03-3013-14/+47
| | | | svn path=/trunk/; revision=9024
* add a "GList *authtypes", so you can get the list of authtypes used by aDan Winship2001-03-221-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-provider.h: (CamelProvider) add a "GList *authtypes", so you can get the list of authtypes used by a provider without needing to have an actual CamelService object handy. (Will be needed by the new config druid.) (CAMEL_PROVIDER_ALLOWS, CAMEL_PROVIDER_NEEDS): New macros to test the URL part stuff, since the way it works is too complicated and everyone always does it wrong. * camel-service.c (camel_service_query_auth_types): Remove the @connected arg again: if you don't want to connect, you can just get the list of authtypes off the provider. (camel_service_free_auth_types): Remove this. All existing implementations do authtypes the same way, so just say the caller should "g_list_free" the list. (Oh, look, removing this function doesn't actually cause the mailer to not build. How 'bout that.) (construct, get_path): Use the new URL part macros. * camel-remote-store.c (remote_query_auth_types): Update (remote_free_auth_types): Nuke (camel_remote_store_authtype_list): New function for use by subclasses. * providers/imap/camel-imap-provider.c: * providers/pop3/camel-pop3-provider.c: * providers/smtp/camel-smtp-provider.c: Update CamelProvider structures. (camel_provider_module_init): Put all the SSL parts together so there's only 1 #ifdef. Set up the provider authtypes field using the SASL, CamelRemoteStore, and standard authtypes, as appropriate. Copy that from the normal provider to the SSL provider. * providers/local/camel-local-provider.c: * providers/sendmail/camel-sendmail-provider.c: * camel-session.c: Update CamelProvider structures. * providers/imap/camel-imap-store.c (query_auth_types): * providers/pop3/camel-pop3-store.c (query_auth_types): Update * providers/smtp/camel-smtp-store.c (query_auth_types): Update. Remove the no_authtype, because that's what "ALLOW_AUTH" rather than "NEED_AUTH" means. (free_auth_types): Nuke. svn path=/trunk/; revision=8872
* Modified patch from Dan Berger <dberger@ix.netcom.com> to re-check theNot Zed2001-03-171-0/+3
| | | | | | | | | | 2001-03-17 Not Zed <NotZed@Ximian.com> * providers/local/camel-maildir-summary.c (maildir_summary_sync): Modified patch from Dan Berger <dberger@ix.netcom.com> to re-check the maildir directory for new/updated messages at sync time. svn path=/trunk/; revision=8781
* Remove some unused stuffDan Winship2001-03-071-59/+0
| | | | | | | | * providers/local/camel-mbox-provider.c: * providers/vee/.cvsignore: * providers/vee/libcamelvee.urls: Remove some unused stuff svn path=/trunk/; revision=8582
* Emit the folder_created signal here.Jeffrey Stedfast2001-02-162-1/+27
| | | | | | | | | | | | | | | | | | | | | | | 2001-02-15 Jeffrey Stedfast <fejj@ximian.com> * providers/vee/camel-vee-folder.c (camel_vee_folder_new): Emit the folder_created signal here. * providers/local/camel-local-folder.c (camel_local_folder_construct): Emit the folder_created signal. * providers/local/camel-local-store.c (delete_folder): On error, free the 'name' string so we don't leak. Also emit the folder_deleted signal. * providers/imap/camel-imap-store.c (subscribe_folder): Emit the folder_created signal. (unsubscribe_folder): Emit the folder_deleted signal. * camel-store.c (camel_store_class_init): Added folder_created and folder_deleted signal defs. svn path=/trunk/; revision=8246
* mbox, mh, and maildir camel-url's need absolute paths.Jeffrey Stedfast2001-02-131-3/+3
| | | | | | | | | | | 2001-02-12 Jeffrey Stedfast <fejj@ximian.com> * providers/local/camel-local-provider.c: mbox, mh, and maildir camel-url's need absolute paths. * camel-provider.h (CAMEL_URL_PATH_IS_ABSOLUTE): New flaggy flag. svn path=/trunk/; revision=8193
* Rewrite a bunch. Replace the existing folder cache stuff with much simplerDan Winship2001-02-104-72/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-store.c: Rewrite a bunch. Replace the existing folder cache stuff with much simpler code that still handles all the existing cases. Now the folder hash table is always created by the base class, using hash and compare functions provided by the class implementation. (If they are set to NULL, CamelStore won't cache folders.) lookup_folder, cache_folder, and uncache_folder are no longer class methods, and get_name is gone completely. (camel_store_get_inbox): Renamed from camel_store_get_default_folder, since that wasn't being used, and this is what we actually need. (camel_store_get_root_folder): Removed, since it's not needed for anything given get_folder_info. * camel-remote-store.c: * providers/local/camel-local-store.c: * providers/local/camel-mbox-store.c: * providers/local/camel-mh-store.c: * providers/local/camel-maildir-store.c: * providers/nntp/camel-nntp-store.c: * providers/pop3/camel-pop3-store.c: * providers/vee/camel-vee-store.c: Minor updates for CamelStore changes * providers/imap/camel-imap-store.c (camel_imap_store_class_init): Update for CamelStore changes. (hash_folder_name, compare_folder_name): treat INBOX case-insensitively, otherwise use g_str_hash and g_str_equal. * camel-service.c (camel_service_construct): Remove camel_service_new and create camel_service_construct (as a class method) in its place. * camel-session.c (camel_session_get_service): Use camel_object_new and camel_service_construct to replace camel_service_new. * providers/local/camel-local-store.c (construct): Append a '/' to the URL path if it doesn't end with one svn path=/trunk/; revision=8145
* Changed to push the operation into a status stack.Not Zed2001-02-081-4/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | 2001-02-07 Not Zed <NotZed@Ximian.com> * camel-operation.c (camel_operation_start): Changed to push the operation into a status stack. (camel_operation_progress): Changed to only accept % complete. (camel_operation_reset): Free status stack as well. * providers/pop3/camel-pop3-folder.c (pop3_get_message): Get the octect count from the return line, and pass it to get_additional_data(). (pop3_refresh_info): Added status stuff. * providers/pop3/camel-pop3-store.c (camel_pop3_command_get_additional_data): Added a total bytes expected argument for progress reporting & fixed callers. (camel_pop3_command_get_additional_data): Added progress reporting. * providers/local/camel-mbox-summary.c (mbox_summary_sync_full): (mbox_summary_sync_quick): (summary_rebuild): Added progress reporting stuff. svn path=/trunk/; revision=8095
* Removed some debug 'warnings', as they should now be displayed at theNot Zed2001-01-231-4/+10
| | | | | | | | | | | | | | | | | | | | | 2001-01-23 Not Zed <NotZed@Ximian.com> * providers/imap/camel-imap-summary.c (message_info_load): Removed some debug 'warnings', as they should now be displayed at the toplevel loader, and just made the code match similar code elsewhere. * providers/local/camel-mbox-summary.c (message_info_load): Error handling. (message_info_save): more error handling. * camel-folder-summary.c (message_info_load): Add error handling and sanity checking. (camel_folder_summary_load): Add error checks. (perform_content_info_load): Error + sanity checks. (content_info_load): error + sanity checks. svn path=/trunk/; revision=7737
* Added profiling temp files.Not Zed2001-01-221-0/+4
| | | | | | | | | 2001-01-22 Not Zed <NotZed@Ximian.com> * .cvsignore */*/.cvsignore: Added profiling temp files. svn path=/trunk/; revision=7705
* Changed the descriptions for mh, mbox, and maildir to be moreJeffrey Stedfast2001-01-111-3/+3
| | | | | | | | | 2001-01-10 Jeffrey Stedfast <fejj@helixcode.com> * providers/local/camel-local-provider.c: Changed the descriptions for mh, mbox, and maildir to be more "user-friendly". svn path=/trunk/; revision=7373
* Lock the command channel while searching. (imap_body_contains): IfNot Zed2000-12-2411-414/+231
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-12-24 Not Zed <NotZed@HelixCode.com> * providers/imap/camel-imap-search.c (imap_body_contains): Lock the command channel while searching. (imap_body_contains): If performing a whole uid search, then add references to our own summary items, dont look it up in the folder. This way they can't vanish unexpectedly. * providers/imap/camel-imap-folder.h (CamelImapFolder): Added a private field. * providers/imap/camel-imap-private.h: Added lock for imap searches. * Merge from camel-mt-branch. * providers/imap/camel-imap-folder.c (imap_update_summary): Merge fix, use the folder->summary. (imap_get_message_flags, imap_set_message_flags, imap_get_message_user_flag, imap_set_message_user_flag): Removed again. (camel_imap_folder_init): Setup private data/lock. (imap_finalize): Free private data/search lock. (imap_search_free): Lock the search_lock. (imap_search_by_expression): Lock the search lock when using the search object. Also copy/ref hte summary, rather than getting it directly. (imap_refresh_info): Free any info lookups. Use folder->summary not imap_folder->summary. And lock around commands. svn path=/trunk/; revision=7150
* change a bunch of IS_CAMEL_* macros to CAMEL_IS_*Dan Winship2000-12-1412-12/+12
| | | | | | | * Namespace cleanup: change a bunch of IS_CAMEL_* macros to CAMEL_IS_* svn path=/trunk/; revision=6972
* Hrm, we actually want to call set_header, not add_header here, probablyNot Zed2000-12-111-4/+34
| | | | | | | | | | | | | | | | | | | | | 2000-12-11 Not Zed <NotZed@HelixCode.com> * camel-medium.c (camel_medium_set_header): Hrm, we actually want to call set_header, not add_header here, probably explains some duplicate X-Evolution headers i was trying to track down. Also changed the api to handle a NULL value == remove the header. * providers/local/camel-maildir-summary.c (maildir_summary_decode_x_evolution): Always return error, we dont use x-evolution for maildir. (maildir_summary_encode_x_evolution): Always return a NULL string, likewise. (maildir_summary_add): Hook in here, since the _new function doesn't have access to any flags from the caller. If we have flags, then update the filename again. Not ideal, but should work. svn path=/trunk/; revision=6897
* Fix the check for "flags aren't actually changing".Dan Winship2000-12-061-3/+12
| | | | | | | | | | | | | | | * providers/imap/camel-imap-folder.c (imap_set_message_flags): Fix the check for "flags aren't actually changing". * providers/local/camel-local-folder.c (local_set_message_flags, local_set_message_user_flag, local_set_message_user_tag): Don't emit message_changed unless the flags actually changed. * providers/nntp/camel-nntp-folder.c (nntp_folder_set_message_flags): Don't emit message_changed unless the flags actually changed. Fix the check for marked as seen. svn path=/trunk/; revision=6797
* stream_flush does make sense for a substream afterall (if you have aNot Zed2000-12-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-12-05 Not Zed <NotZed@HelixCode.com> * camel-seekable-substream.c (stream_flush): stream_flush does make sense for a substream afterall (if you have a stream_write). (stream_write): Implement this. (stream_seek): Change the STREAM_END behaviour to be more sane. if bounded go from the end of the bound, if unbounded, go from the end of the parent stream. * camel-stream-mem.c (stream_read): Dont return error if reading past the end of data, just return 0. * camel-stream-fs.c (camel_stream_fs_init): Initialise the stream to be unbound. (stream_seek): Fix the logic when seeking from the end of an unbounded stream. (camel_stream_fs_new_with_fd): If the fd is invalid (-1), then return NULL immediately. (stream_seek): Range check a SEEK_END so it fits within bound_start. 2000-12-01 Not Zed <NotZed@HelixCode.com> * tests/lib/folders.c (test_folder_basic): New test to perform basic store operations on folders (taken from folders/test1). (test_folder_message_ops): Tkane the guts out of folders/test2. svn path=/trunk/; revision=6790
* Remove assertion that content is there, when it no longer can be.Not Zed2000-11-3010-69/+232
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-30 Not Zed <NotZed@HelixCode.com> * providers/local/camel-mbox-folder.c (mbox_get_message): Remove assertion that content is there, when it no longer can be. * camel-folder-summary.h: Removed pos/bodypos/endpos from camelmeessagecontentinfo. (CamelMessageFlags): Added an attachments flag. * providers/local/camel-local-summary.h: Added load virtual function. * tests/lib/folders.c (test_message_info): Accessors. (test_folder_message): " * camel-folder-thread.c (get_root_subject): Fix accessors. (dump_tree_rec): " * camel-folder-search.c (camel_folder_search_execute_expression): Accessors for messageinfo. (search_match_all): " (search_header_contains): " (search_header_contains): " (search_body_contains): " (camel_folder_search_execute_expression): Use mepool_strdup. * providers/local/camel-mbox-summary.c (summary_update): Accessors for messageinfo. (mbox_summary_sync_full): " * providers/local/camel-mh-summary.c (remove_summary): Accessors for messageinfo. (mh_summary_check): " (mh_summary_sync_message): " (mh_summary_sync): " * providers/local/camel-mh-folder.c (mh_append_message): Use accessor for uid. * providers/local/camel-local-summary.c (local_summary_decode_x_evolution): Use accessor to uid. (local_summary_encode_x_evolution): Likewise. (message_info_new): And here. (camel_local_summary_load): Call virtual load function. (local_summary_load): Default load function, load summary. (camel_local_summary_load): Check file exists before trying to load. (camel_local_summary_construct): Turn off building content info! (CAMEL_LOCAL_SUMMARY_VERSION): Bump, since we dont build content info anymore. (camel_local_summary_load): After a successful load/check, do a save too so we dont have to go through it again randomly. * providers/nntp/camel-nntp-utils.c (get_XOVER_headers): Use accessors for messageinfo. * providers/nntp/camel-nntp-folder.c (nntp_folder_get_uids): Use accessors for uid. * providers/imap/camel-imap-folder.c (imap_refresh_info): Use accessor for uid. (imap_sync): Likewise. (imap_get_uids): Likewise. (imap_update_summary): And here. * providers/vee/camel-vee-folder.c (vfolder_remove_match): Use accessor for uid. (vfolder_add_match): Handle estrv stuff. (vfolder_change_match): Accessor for uid. (get_real_message): " (vee_get_uids): " (vee_folder_build): " + estrv. (vee_folder_build_folder): " * providers/local/camel-maildir-folder.c (maildir_append_message): Use acccessors for uid's. (maildir_get_message): Here too. * providers/local/camel-maildir-summary.c (camel_maildir_summary_init): Setup the string count for us. (message_info_new): Access the string array directly. (message_info_free): No need to free string if using array. (camel_maildir_summary_info_to_name): Use accessor to get to uid. (remove_summary): And here. (maildir_summary_check): Likewise. (maildir_summary_sync): And here. (maildir_summary_load): Load up a cache of uid->filename mappings before loading the actual summary file. This saves us having to waste the diskspace storing the filenames in the summary itself, and also helps us sync the summary better on load. (message_info_load): If we have the load_map setup, and the uid exists, then set the filename cache from it, and update the flags from the name, incase our summary mismatches it. * camel-folder-summary.c (camel_folder_summary_init): Setup string count for compressed info record. An optional compile mode which stores all strings for a given messageinfo into a packed array, which should save 36-50 bytes/record. (camel_folder_summary_info_new): Init the string array. (message_info_new): Set the string array items, as required. (message_info_load): And here too. (message_info_save): Use accessors to get to strings. (message_info_free): Free strings as one. (camel_message_info_dup_to): Handle packed array case. (camel_folder_summary_add): Use accessors. And pack the strv before storing it. (summary_assign_uid): New function to assign a unique uid to a message, if it doesn't have one. (camel_folder_summary_add): Call assign_uid instead of doing it ourselves. (camel_folder_summary_info_new_from_parser): " (camel_folder_summary_info_new_from_message): " (camel_folder_summary_encode_string): constify. (camel_folder_summary_encode_token): " (summary_build_content_info_message): Fix accessors to messageinfo. (CAMEL_FOLDER_SUMMARY_VERSION): Bumped, for removal of contentinfo->pos data. (camel_folder_summary_info_new_from_parser): Calculate the size based on the parser position, not the removed contentinfo stuff. (camel_folder_summary_info_new_from_message): Remove size stuff. (camel_folder_summary_offset_content): Removed, no longer means anything. (content_info_new): (content_info_load): (content_info_save): (summary_build_content_info): Remove stuff for contentinfo->pos*. (summary_build_content_info): Take a msginfo argument, set attachments flag if we find any attachments. (summary_build_content_info_message): set attachments flag if we find any attachments. (camel_folder_summary_info_new_from_parser): Always scan the content info, even if we dont save it. (camel_folder_summary_info_new_from_message): And here too. (summary_build_content_info): Only create the contentinfo stuff if we have it turned on, otherwise just parse and discard. (summary_build_content_info_message): Likewise. svn path=/trunk/; revision=6731
* Add a missed unref.Not Zed2000-11-296-8/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-29 Not Zed <NotZed@HelixCode.com> * tests/message/test2.c (main): Add a missed unref. * camel-stream-mem.c (camel_stream_mem_set_buffer): We must set ourselves as the owner of the byte-array. Weird, someone has modified this file (its been reindented), but i can't see any changelogs ... * tests/lib/messages.c (content_finalise): Fix memleak in tester, free byte array when our content object is deleted. * camel-folder-search.c (camel_folder_search_finalize): Yeah great, so the sexp is a gtk object, not a camel object. Isn't that going to be fun to fix? * camel-session.c (camel_session_finalise): Free the storage path. * providers/local/camel-local-store.c (camel_local_store_init): If store->folders is setup, free it first, then overwrite. Hmm, this seems a bit crappy to me. * camel-store.c (camel_store_init): Dont setup store->folders if its already setup. * camel-exception.c (camel_exception_setv): Removed a memleak. no need to strdup after a strdup_printf!!! * camel-address.c (camel_address_finalize): Free the address ptrarray, once finished. * providers/local/camel-local-folder.c (local_finalize): Make sure we dont leave the folder locked on close. (local_finalize): Free summary/search. * providers/local/camel-mh-summary.c (mh_summary_next_uid_string): Small memleak, always free name after using it. * camel-mime-part.c (set_content_object): Free txt after setting the header. * providers/local/camel-maildir-summary.c (maildir_summary_check): Fix a memleak, close the dir after scanning new. (message_info_free): Added so we can free the filename cached in the messageinfo. (camel_maildir_summary_finalise): Free the hostname. * tests/folder/test[12].c (main): Clear out camel-test before starting. * providers/local/camel-mbox-summary.c (mbox_summary_sync_quick): Because encode_x_evolution folds the line (sigh, because encode_param does, unlike every other function in camel-mime-utils), unfold the encoded result before comparing. (mbox_summary_sync_quick): Another small memleak, free xevnew once finished with it. * camel-mime-utils.c (header_decode_quoted_string): Removed a redundant check for c=0. (header_unfold): New function to un-fold headers. * providers/local/camel-local-summary.c (local_summary_encode_x_evolution): some problems with encoding tags, using the wrong output strings. (local_summary_encode_x_evolution): We dont need to append a ; either, param_list_format_append() will do it for us. ` svn path=/trunk/; revision=6711
* Set the info size's properly, oops!Not Zed2000-11-289-51/+191
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-28 Not Zed <NotZed@HelixCode.com> * providers/local/camel-maildir-summary.c (camel_maildir_summary_init): Set the info size's properly, oops! * tests/lib/folders.[ch]: Folder testing helpers. * tests/folder/test2.c: Test basic message ops on folders. * tests/folder/test1.c (main): Test basic folder ops on (local) stores. * providers/local/camel-local-provider.c (camel_provider_module_init): Removed some debug. * providers/local/camel-maildir-folder.c (camel_maildir_folder_class_init): fix parent class. * providers/local/camel-mh-folder.c (camel_mh_folder_class_init): Fix parent class (damn cut & paste). * providers/local/camel-maildir-store.c (get_folder): Call parent impl. (camel_maildir_store_class_init): Fix parent class setup. (delete_folder): Check the folder exists before trying to delete it. (delete_folder): Try and make the delete operation atomic/rollback failures. e.g. if one directory isn't empty, then create the other empty ones back. Also clear the tmp directory fully first. * providers/local/camel-mbox-store.c (get_folder): Call parent impl. (camel_mbox_store_class_init): parent class is camel_local_store, not camel_folder, oops. (delete_folder): Return an error if it doesn't exist, rather than covering it up. * providers/local/camel-mh-store.c (get_folder): Call parent impl. (camel_mh_store_class_init): fix parent class setup. (delete_folder): Error if it doesn't exist now. * camel-folder.c (camel_folder_move_message_to): (camel_folder_copy_message_to): Added warnings as these functions are going to be removed later. * camel-store.c (camel_store_get_root_folder): Fix for an early api change. We want CAMEL_STORE_FOLDER_CREATE, not TRUE, since its a flag. (camel_store_get_default_folder): And here too. * providers/local/camel-local-store.c (xrename): Handle renaming folders differently to renaming files. (get_default_folder_name): local stores dont have a default folder, so make it so. Or at least, it doesn't seem to make sense to have one. (get_root_folder_name): Same for root. (get_folder): Added parent implementation, that makes sure the service path exists, if we are creating a new folder (but doesn't create the folder). 2000-11-27 Not Zed <NotZed@HelixCode.com> * providers/local/camel-local-store.c (xrename): Fixed races. Use link/unlink, rather than rename, to properly detect overwriting another file. And allow some files to be missing. * providers/Makefile.am: Removed mh, mbox, added local, to the default. svn path=/trunk/; revision=6693
* add scan = scan->next; to avoid infinite loopRadek Doulik2000-11-281-0/+1
| | | | | | | | | | 2000-11-28 Radek Doulik <rodo@helixcode.com> * providers/local/camel-local-summary.c (local_summary_decode_x_evolution): add scan = scan->next; to avoid infinite loop svn path=/trunk/; revision=6690
* Remove "complete" fieldJP Rosevear2000-11-281-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-27 JP Rosevear <jpr@helixcode.com> * conduit/address-conduit.h: Remove "complete" field * conduit/address-conduit.c (print_local): Make it print useful debug info (print_remote): ditto (local_record_from_ecard): Make sure phone numbers get out to the pilot (ecard_from_remote_record): Set phone strings to "" if they are null (sequence_complete): unref the book view (view_cb): ref the book view (free_prepare): do nothing * backend/pas/pas-backend-file.c (pas_backend_file_book_view_free): Destroy the card lists with the rest of the view. (pas_backend_file_changes): Don't destroy the card lists here (pas_backend_file_book_view_free): Free the card/id lists in the change context here, the correct place. (pas_backend_file_changes): instead of here... 2000-11-27 JP Rosevear <jpr@helixcode.com> * conduits/todo/todo-conduit.c (free_prepare): Ditto * conduits/calendar/calendar-conduit.c (free_prepare): Adjust free_prepare to the correct signal parameters. Don't actually do anything - there is a semantic discrepancy that needs to be resolved. 2000-11-27 JP Rosevear <jpr@helixcode.com> * providers/local/.cvsignore: shush svn path=/trunk/; revision=6681
* Shite, -1 on error, >=0 on success. So i've just been truncating all theNot Zed2000-11-211-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-21 Not Zed <NotZed@HelixCode.com> * providers/local/camel-mh-summary.c (mh_summary_sync_message): Shite, -1 on error, >=0 on success. So i've just been truncating all the messages I touched, good one zed. (mh_summary_sync_message): Sigh, and write to the right damn fd as well. (mh_summary_sync_message): Argh, and we need to compare the length of the old xev -1 to the new xev, to check if we can optimise it. * camel-folder.c (camel_folder_change_info_new): Init the pool. (camel_folder_change_info_add_source): Allocate string in the pool. (camel_folder_change_info_add_source_list): (camel_folder_change_info_add_update): No longer free the key, as it cannot be yet. (change_info_add_uid): Add a new arg, copy, telling it whether to copy the uid argument or not, and copy using mempool_strdup. (change_info_cat): Tell add_uid to copy the string. (camel_folder_change_info_add_update): Call add_uid directly. (change_info_remove): Call add_uid directly, with no copy, and dont free the key. (change_info_free_update): No longer required since we dont malloc the keys. (camel_folder_change_info_add_uid): Fix for add_uid change. (camel_folder_change_info_remove_uid): (camel_folder_change_info_change_uid): (change_info_clear): No longer needed, just set the size to 0 on the array directly. (camel_folder_change_info_clear): Empty the arrays directly, and flush the mempool too, and also clear uid_source, incase anyone was silly enough to call us in the wrong order. (camel_folder_change_info_free): Dont bother clearing the array's contents, just free the pool and throw away all the indexes. * camel-folder.h: Added a mempool to CamelFolderChangeInfo to store the uid's we get. * camel-folder-search.c (search_match_all): If we are only matching a single info, just use that/do the search. (camel_folder_search_match_expression): New function. Matches a single message info against an expression. (camel_folder_search_init): Init a hash table used to map the returned gptrarrays' to mempools. (camel_folder_search_execute_expression): Store all of the string data in a mempool, slightly faster, less wasted space (usually),. (camel_folder_search_free_result): Check for the mempool that stores the data for the list, and free that if we have it, otherwise assume we need to use g_free() (which should only happen if the list is empty at the moment). : commented out the debugging prints. Got sick of 'executing header search' crap. * providers/vee/camel-vee-folder.c (camel_vee_folder_init): Init changes. (camel_vee_folder_finalise): Free changes. (vfolder_add_match): Simple helper to add a new matching info record. (camel_vee_folder_add_folder): Only trigger a changed event if we have changes. (vfolder_change_match): New function, changes our local vfolder info to match the source. (vfolder_add_match): Add a new info to the vfolder list. (vfolder_remove_match): Remove a no-longer matching info from the vfolder summary. (message_changed): check if the message still matches, and remove/etc as required. (camel_vee_folder_finalise, init): init/free search object. (vee_folder_build_folder): Build the changes to the folder into the changes data, as we go. (folder_changed): If the folder gave us an explicit list of changes, then process each one separately (unless there's a lot added/changed). * providers/vee/camel-vee-folder.h: Added a changes field to the folder. svn path=/trunk/; revision=6628
* Fixes for the summary messageid changes. Hash the messageid and store it.Not Zed2000-11-217-341/+561
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-20 Not Zed <NotZed@HelixCode.com> * providers/nntp/camel-nntp-utils.c (get_XOVER_headers): Fixes for the summary messageid changes. Hash the messageid and store it. (get_XOVER_headers): Use camel_folder_summary_info_new() to create the summary item before adding it. * camel-folder-summary.h (CamelMessageInfo): Changed the messgae-id to be an 8 byte md5 hash, and the references list to be an array of these. * providers/local/camel-mh-summary.c (mh_summary_sync_message): New function, sync out the message info stuff. Only updates the X-Ev header if it can get away with it, otherwise writes out a whole new message. (mh_summary_sync): Added more functionality. All summary info is now written to the X-Ev header, etc, and new messages re-written if required during the sync process. * providers/local/camel-local-folder.c (local_set_message_user_flag): Set the XEVCHANGE flag. (local_set_message_user_tag): And here too. * providers/local/camel-local-summary.h: New flag CAMEL_MESSAGE_FOLDER_XEVCHANGE to indicate the XEV header has probably changed size and needs to be rewritten in whole. * camel-folder-summary.c (next_uid_string): Want this static, not const. (message_info_new): Store the references and message-id values as 64 bit, binary hashes. (message_info_load): fix for message-id/references changes. (message_info_save): Likewise. (camel_message_info_dup_to): And here. (camel_message_info_free): And here too. No longer free message_id, and simple free for references array. (CAMEL_FOLDER_SUMMARY_VERSION): Bumped file revision. (camel_folder_summary_init): Init memchunk allocators to empty. (camel_folder_summary_finalize): Free memchunk allocators if there. (message_info_new): Use the chunk allocator to allocate message info's. (camel_folder_summary_info_new): New helper to allocate the message info, and setup the memchunk if required. (content_info_alloc): Likewise for content info's. (message_info_load): Use summary_info_new_empty. (content_info_new): Use content_info_alloc. (content_info_load): " (content_info_free): Free the content info as a memchunk. (message_info_free): Free everything directly and the base as a memchunk, rather than calling camel_message_info_free(), which assumes a malloc'd array. * providers/local/camel-local-summary.c: Include ctype.h, kill a warning. (local_summary_decode_x_evolution): If we get a NULL message info, then dont try and set anything, just check for validity. (camel_local_summary_write_headers): New function to write a set of headers to an fd. (camel_local_summary_check): Added some statistic generation stuff for memory profiling. * providers/local/camel-mbox-summary.c (header_write): Changed to use stdoi functions to write out the header to a buffered stream, instead of using writev, which is apparently slow (and writing each line separately is slow anyway). (mbox_summary_sync_full): New implementation. Does things differently, doesn't use or require the content info stuff. (summary_rebuild): Dont return an error if we start scanning at the end of file. (mbox_summary_sync_full): If we are not writing out new headers, make sure we copy the From line as we go, and update frompos appropriately. (mbox_summary_sync_full): Always copy the From line from the existing one, rather than trying to make one up ourselves. (mbox_summary_sync): If we can get by with a quick-sync, then try it, if that fails, then try a full sync anyway. (mbox_summary_sync_quick): Quick sync. Only update system flags, etc. (mbox_summary_sync_full): Use the proper local summary encode_xev function. (header_evolution_decode): Removed, no longer needed. (header_evolution_encode): Same. (copy_block): No longer needed, removed. (header_write): Removed, replaced with camel_local_summary_write_headers. (mbox_summary_sync_full): Fixed for header_write change. * camel-mime-parser.c (folder_scan_step): Implement the new optional parser state HSCAN_PRE_FROM, that returns the (currently unfiltered) input data. (folder_scan_drop_step): Do the right thing for the PRE_FROM state. (camel_mime_parser_scan_from): Update the doco. (camel_mime_parser_scan_pre_from): Ok, make this behaviour optional, it simplifies a lot of loops that dont otherwise need to know about it. (folder_scan_step): Made the PRE_FROM state optional. (struct _header_scan_state): Made the bool vars 1 bit. (folder_pull_part): Free the from_line buffer if it is there. (folder_scan_skip_line): Added a new arg, can save the skpped data to a byte_array, as we go. (folder_scan_step): Fixed calls to skip_line approrpiately. Now we save the from line as we parse it. (camel_mime_parser_read): New function to read from the mime parser buffer directly. Useful if you use the parser to read the first/some headers, then need to scan the rest of the data, without needing to use a seek(), or allocate your own buffers. * camel-mime-parser.h (struct _header_state): Added a new parser state, pre-from which returns any data found before a from line during parsing (all other data can be retrieved by the caller except this). svn path=/trunk/; revision=6618
* We should always terminate the string. No need to check outptr is inNot Zed2000-11-172-7/+4
| | | | | | | | | | | | | | | | | | 2000-11-17 Not Zed <NotZed@HelixCode.com> * camel-stream-buffer.c (camel_stream_buffer_gets): We should always terminate the string. No need to check outptr is in range, its already been checked. * providers/local/camel-mbox-summary.c (mbox_summary_sync): When we update the summary, do it from mbox_summary->folder_size, not the content info endpos (which isn't any good anymore anyway). * providers/local/camel-mbox-folder.c (mbox_append_message): Set the frompos from the current folder size, since summary_add wont have initialised it to anything useful. svn path=/trunk/; revision=6597
* Check the uid string is all digits before trying to write a 'standard'Not Zed2000-11-169-230/+307
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-16 Not Zed <NotZed@HelixCode.com> * providers/local/camel-local-summary.c (local_summary_encode_x_evolution): Check the uid string is all digits before trying to write a 'standard' x-ev header. * providers/local/camel-maildir-summary.c (camel_maildir_summary_info_to_name): Convert an info into a maildir name:info filename. (camel_maildir_summary_name_to_info): Convert a name:info filename into an info, and tell us if it didn't match it. (message_info_new): When creating a new filename, gets its info from the flags field. Likewise if creating from an existing file, extract the flags. (maildir_summary_sync): Remove a small memleak. Also, if our flags and that requires a filename change, perform that here. (message_info_new): Get the received date from the filename. Also, dont overwirte the uid if we have one. (maildir_summary_check): Sort the summary in received order before completion. (maildir_summary_next_uid_string): Test the name for collusions before we give it out. Retry, and if that fails, well, I guess we collide :( * providers/local/camel-mbox-folder.c (mbox_lock): Implement mbox locking. (mbox_unlock): And unlocking. (mbox_append_message): Lock the folder for write before doing anything. (mbox_get_message): Lock the folder for read before doing anything. * providers/local/camel-local-folder.c (camel_local_folder_lock): Implement something here. We handle the recursive ability but pass the locking to the folder itself. (camel_local_folder_unlock): Likewise for unlocking. (local_lock): Default - do nothing, return success. (local_unlock): Same. (local_sync): Changed slightly for locking api changes, and also, only lock around the sync process itself. * camel-lock.c: New file - utility functions for locking using different strategies and/or for locking folders safely. * Makefile.am (libcamel_la_SOURCES): Adde camel-lock.[ch] svn path=/trunk/; revision=6592
* New file - utility functions for locking using different strategies and/orNot Zed2000-11-161-4/+1
| | | | | | | | | | | 2000-11-16 Not Zed <NotZed@HelixCode.com> * camel-lock.c: New file - utility functions for locking using different strategies and/or for locking folders safely. * Makefile.am (libcamel_la_SOURCES): Adde camel-lock.[ch] svn path=/trunk/; revision=6590
* Maildir lives.Michael Zucci2000-11-1513-17/+1005
| | | | svn path=/trunk/; revision=6576
* Initial cut for local provider, to handle mh/mailbox/maildir atMichael Zucci2000-11-1522-0/+4165
least. Checking in to make a backup. svn path=/trunk/; revision=6575