aboutsummaryrefslogtreecommitdiffstats
path: root/camel
Commit message (Collapse)AuthorAgeFilesLines
* Go until inend, not inend+1. Changed the continuation and retry logic toNot Zed2000-11-111-187/+134
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-11 Not Zed <NotZed@HelixCode.com> * camel-mime-parser.c: (folder_scan_content): Go until inend, not inend+1. Changed the continuation and retry logic to be simpler and more robust. If we can't find a marker within the atleast we need, just set it to 1, and try again, rather than just going to the next smaller limit (boundary check checks the length anyway). (header_append): streamline the empty line case. And strip trailing \r's if there are any (\n's already stripped). (folder_scan_header): Reordered and cleaned up a lot. Check for continuation only once, and compress lwsp then. Assume the header buffer already has end of line's stripped, and simplify some things: Only check for end of headers once and easier. Dont check to remove end of line character Dont bother testing inptr-start if we get a boundary match - it is always zero. (folder_scan_header): Removed the unused part variable, and a few pointless assignments. (folder_scan_header): Change the end limit to be 1 higher, to make sure we get all content. (folder_scan_content): And here too. (folder_scan_header): Killed a warning. (folder_push_part): Removed a bad comment. Actually boundarylenfinal can be zero for a new message not in a multipart. So we fix that here. svn path=/trunk/; revision=6542
* Make sure 'atleast' is at least 1, always. This is possibly a temporaryNot Zed2000-11-111-3/+4
| | | | | | | | | | 2000-11-11 Not Zed <NotZed@HelixCode.com> * camel-mime-parser.c (folder_push_part): Make sure 'atleast' is at least 1, always. This is possibly a temporary fix for a bad failure mode on bad multipart messages. svn path=/trunk/; revision=6540
* put a space before a single-digit day of the month since it seems someDan Winship2000-11-112-1/+8
| | | | | | | | | * providers/mbox/camel-mbox-summary.c (camel_mbox_summary_build_from): put a space before a single-digit day of the month since it seems some mailers are fantastically picky about this. (bugs.gnome.org #27232) svn path=/trunk/; revision=6538
* fix ids ending with '.'Radek Doulik2000-11-112-1/+6
| | | | | | | | 2000-11-10 Radek Doulik <rodo@helixcode.com> * camel-mime-utils.c (header_msgid_generate): fix ids ending with '.' svn path=/trunk/; revision=6536
* Fix error handling. (Only send a "*" to bail out of authentication if theDan Winship2000-11-102-9/+19
| | | | | | | | * providers/imap/camel-imap-auth.c (imap_try_kerberos_v4_auth): Fix error handling. (Only send a "*" to bail out of authentication if the server hasn't already bailed on us.) svn path=/trunk/; revision=6520
* new function, moved from composerRadek Doulik2000-11-083-0/+29
| | | | | | | | | 2000-11-08 Radek Doulik <rodo@helixcode.com> * camel-mime-utils.c (mime_guess_type_from_file_name): new function, moved from composer svn path=/trunk/; revision=6506
* Keep track of the caller bestenc flags that make sense.Not Zed2000-11-087-137/+237
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-08 Not Zed <NotZed@HelixCode.com> * camel-mime-message.c (find_best_encoding): Keep track of the caller bestenc flags that make sense. * camel-mime-filter-bestenc.c (filter): Added code to detect when we have "^From " lines in the sequence of text. (camel_mime_filter_bestenc_get_best_encoding): Added a new flag CAMEL_BESTENC_NO_FROM: if set, it will not allow any lines matching "^From " to appear in the output - currently forcing base64 encoding to achieve this. * camel-mime-parser.c (folder_scan_step): Call camel_mime-filter_complete() once we're done, rather than filter_filter(). (folder_scan_content): Some fixes for state changing; so that when we do find another boundary it is properly flagged. Since we strip the last \n off all data, we must take that into account too. Sigh. Fixes a rather nasty set of bugs where multipart messages could start including following messages as parts, etc. (struct _header_scan_stack): Added new parameter, boundarylenfinal, which holds the length of the final boundary, if it is different (e.g. for From lines, whihc aren't) (folder_scan_step): Setup teh boundarylenfinal value when creating a new boundary. (folder_scan_content): Hmm, if we hit the end-of-buffer sentinal, reset the scanner back to leave 'atleast' chars in the buffer still, dump that content, and retry again. Stops us losing a check for a boundary on some data we haven't really looked at yet! (folder_scan_content): Use boundarylenfinal to calculate 'atleast'. (folder_scan_header): And here too. (folder_boundary_check): Use the atleast value directly, dont truncate it. Use the boundarylen/boundarylenfinal values directly too. (struct _header_scan_stack): Add an atleast parameter to cache the atleast info. (folder_push_part): Determine/set 'atleast', every time we add a new part. (folder_scan_header): Get the cached atleast info from the current part. (folder_scan_content): And here too. (folder_scan_header): Fix a problem where a part starting with " text" would be interpreted as a followon header wrongly. * camel-mime-filter-charset.c (complete): Add some assertions to find a bug. svn path=/trunk/; revision=6500
* Fix the default implementation for CamelService::get_name() so that itEttore Perazzoli2000-11-082-1/+6
| | | | | | | returns a malloced string instead of a static one. (A static one breaks the semantics of the method.) svn path=/trunk/; revision=6483
* Kill debugging, as it causes lots of evolution-mail spewage.Dan Winship2000-11-082-1/+6
| | | | | | | * camel-stream-filter.c (d): Kill debugging, as it causes lots of evolution-mail spewage. svn path=/trunk/; revision=6482
* Oops, forgot to commit. New stream/filter for doingMichael Zucci2000-11-074-0/+460
| | | | | | cool stuff. svn path=/trunk/; revision=6480
* Implement a complete() function, now we need one. (filter): Upgraded toNot Zed2000-11-0720-543/+1703
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-07 Not Zed <NotZed@HelixCode.com> * camel-mime-filter-bestenc.c (complete): Implement a complete() function, now we need one. (filter): Upgraded to match rfrc2045 properly. Checks also for length of line and valid CRLF sequences. (camel_mime_filter_bestenc_get_best_encoding): Do the work of working out what is the best encoding given what we found about the stream. * camel-mime-part.c (camel_mime_part_encoding_to_string): Use a lookup table to get the encoding naem, and add the binary type. (camel_mime_part_encoding_from_string): Likewise for the reverse. * camel-mime-part.h: Added the binary encoding type, see rfc2045. * camel-mime-utils.c (header_param_list_format_append): Dont put a space before ;'s in parameter lists, makes them more readable/consistent. * camel-mime-message.c (multipart_has_8bit_parts): Cleaned up the old stuff, well removed it. (camel_mime_message_set_best_encoding): Added another argument that lets you select what you want to set the best of. i.e. for smtp transport we only need 7 bit, and dont need to optimise the charset (although of course, we should always). (find_best_encoding): Implement this feature, if we are not getting the best charset, use the one we have. (best_encoding): Set the charset on the part appropriately. Sigh, the interfaces for this are nonexistant. (find_best_encoding): Tell the bestenc filter that lf should be treated as crlf for the purposes of determining encodings. 2000-11-06 Not Zed <NotZed@HelixCode.com> * camel-charset-map.c (camel_charset_init): Init function for an iterative charset determinator. (camel_charset_step): Iterate another buffer. (camel_charset_mask): Removed, since it couldn't have worked. (camel_charset_best): Use the iterative interface to do the work. (camel_charset_best_name): Get the best name for a charset so far. * camel-mime-filter-bestenc.c: New class, a stream filter that can be used to memory-efficiently determine the best encoding and/or charset to use for a given stream of bytes. * Makefile.am (libcamelinclude_HEADERS): Added stream-null*. (libcamel_la_SOURCES): Added bestenc* * camel-stream-null.c: New class, a null-stream, that always succeeds, and never has any contents. * camel-stream.c: Minor pointless changes. Was going to do something else but changed my mind. Added trivial default implementations for all callbacks. * camel-mime-message.h: Cleaned up some old cruft. * camel-folder-summary.c (camel_folder_summary_format_address): address_list_format() no longer encodes, so we dont need to decode it. * camel-address.c (camel_address_unformat): New function, attempts to reverse the formatting process on display addresses. (camel_address_length): New function to get the number of addresses, without having to peek the structure. * camel-mime-message.c (camel_mime_message_set_from): Fix a typo. (camel_mime_message_finalize): Only unref from/reply_to if we have it. (camel_mime_message_set_recipients): New function - set the recipients as a CamelInternetAddress. This function effectively deprecates the older recipient setting functions. (camel_mime_message_add_recipient): What the hell, i'll bite the bullet. Terminate this function. The old api was ambiguious and inefficient and didn't work right anyway. (camel_mime_message_remove_recipient_address): And this one. (camel_mime_message_remove_recipient_name): And this one too. (camel_mime_message_set_recipients): If we set an empty header, then remove it from the header list. Allow a null receipient object to clear a header. (camel_mime_message_set_from): Likewise, if setting an empty from address. (camel_mime_message_encode_8bit_parts): Eeek!! camel_stream_mem_new_with_byte_array owns the byte_array we give it, so make sure we dont free any of it! (camel_mime_message_encode_8bit_parts): Infact, i'll just rewrite the whole lot, its a bit of a mess. Should really rename it and make it a little more useful too, lets see ... (best_encoding): This has a string interface? Oh boy. (camel_mime_message_foreach_part): New experimental function to iterate over all message parts. Might not remain. (camel_mime_message_has_8bit_parts): New implementation using foreach_part. Fixed a couple of problems. (find_best_encoding): New function, that finds the best encoding for a given part (will probably be moved to camel-mime-part), and also the best charset to use if it is a text part. Since one affects the other it is a two pass process, but uses streams and not memory to achieve this. (camel_mime_message_set_best_encoding): Uses the function above to configure an entire message for the best encoding possible given transport constraints. (camel_mime_message_encode_8bit_parts): Reimplemented to use the function above to perform the work. * camel-internet-address.c (camel_internet_address_format_address): Dont put <> around a lone address with no real name. (camel_internet_address_encode_address): Similarly. (internet_decode): Actually return the count of decoded addresses. (internet_unformat): Implement the unformatting routine. 2000-11-05 Not Zed <NotZed@HelixCode.com> * providers/smtp/camel-smtp-transport.c (_send_to): Changed to get the internetaddress directly, rather than having to parse it itself. * camel-address.c (camel_address_format): Added a new function which will format address, suitable for display. (camel_address_cat): Concatentate 1 camel address onto another. It is upto the caller to ensure the addresses are of compatible types. (camel_address_new_clone): New function to create a new address by copying an existing one of the same type. (camel_address_copy): New helper function to copy an address. * camel-mime-message.h (struct _CamelMimeMessage): Removed cached copy of date string. (struct _CamelMimeMessage): Added date_received info. * camel-mime-message.c (camel_mime_message_get_date_string): Removed. Nothing uses it anyway, and it is redundant. (camel_mime_message_finalize): No more date_str. (camel_mime_message_init): No more date_str, initialise date_received* (write_to_stream): Change the check for a date header. (process_header): No longer track the date_str. (camel_mime_message_get_received_date): Removed. totally invalid anyway. (camel_mime_message_get_sent_date): Removed. Redundant. The only 'date' is the sent date, the received date is just made up. (camel_mime_message_get_date): Args changed to be more consistent with utility functions. (camel_mime_message_get_date): Dont set the date when we're asked for it (if its not set by the time its written, it'll be set then). (camel_mime_message_get_date_received): Actually do 'the right thing' here, if we have a received header, use that to determine the received date. And return the data in the same format as get_date. (camel_mime_message_set_from): Changed the api to better match what we should be doing. Pass a camelinternetaddress, etc. (camel_mime_message_set_reply_to): Cahnged similarly to take an internetaddress. (camel_mime_message_get_reply_to): Likewise. (camel_mime_message_finalize): Unref the from/reply_to objects. (format_address): Removed, no longer needed. (process_header): Changed to store the from/reply_to as internetaddress's. (write_to_stream): Set the from header directly to empty, if we dont have one. Maybe we should just abort, and/or create one based on the current user. * camel-mime-utils.c (header_address_list_format): Renamed to header_address_list_encode, which is what it is actually doing. (header_address_list_format_append): Similarly. (encoding_map[]): Removed, no longer used. (header_address_list_encode_append): Take another arg, do we encode the address (for internet), or not (for display - utf8 only). (header_address_list_format): Re-added this function, but now it generates a display version only. Surprise surprise, that is all anythign needs to generate anyway. Sigh. * camel-internet-address.c (camel_internet_address_get): Return false if we get an invalid index only. (camel_internet_address_encode_address): Helper function to encode a single address for mailing. (internet_encode): Use the above function to format it. (camel_internet_address_format_address): Format a single address for display. (internet_format): Implement the display version. (camel_internet_address_class_init): Init the internet_format virtual function. (internet_cat): Implement virtual function to concatenate addresses. * camel-folder-summary.c (camel_folder_summary_info_new_from_header): new function, only build the summary info, dont add it. (camel_folder_summary_info_new_from_parser): Likewise, for new info from parser. (camel_folder_summary_add_from_parser): Cahnged to call function above to build info. (camel_folder_summary_add_from_header): Changed to call function above, to build info. (camel_folder_summary_info_free): New function to free the summary message info. (camel_folder_summary_clear): Changed to clal above to free info. (camel_folder_summary_remove): Likewise. (camel_folder_summary_add): Cleaned up the clashing uid re-assignment logic a little bit. (camel_folder_summary_decode_uint32): Fixed a typo, 01 != -1. (camel_folder_summary_decode_time_t): Return -1 on error. (camel_folder_summary_encode_off_t): New function to encode an off_t type. (camel_folder_summary_decode_off_t): And likewise for the reverse. (CAMEL_FOLDER_SUMMARY_VERSION): Bumped the summary version, since we're now encoding time/off_t's right. (summary_header_save): Use time_t encoder to save the timestamp. (summary_header_load): Likewise for decoding the timestamp. (content_info_load): Decode off_t types directly, now we can. (content_info_save): And likewise for encoding. (camel_folder_summary_add_from_message): New function, create a summary item from an existing message and add it. (camel_folder_summary_info_new_from_message): New function, create a summary item from an existing message. (summary_build_content_info_message): New function to do the dirty work of building the conent info/indexing, from a message source. (format_recipients): Format an internetaddress suitable for the summary. (message_info_new_from_message): Build a new summary item from a mime message. (content_info_new_from_message): Build a new conent info from a mime part. (camel_folder_summary_class_init): Init the new class functions. (message_info_new_from_message): Fixed for message api change. Added documentation to the functions. svn path=/trunk/; revision=6474
* Two segfault fixesPeter Williams2000-11-072-1/+6
| | | | svn path=/trunk/; revision=6472
* new function, generates simple message/content idRadek Doulik2000-11-043-0/+21
| | | | | | | | | 2000-11-03 Radek Doulik <rodo@helixcode.com> * camel-mime-utils.c (header_msgid_generate): new function, generates simple message/content id svn path=/trunk/; revision=6389
* Set the preface/postface from the parser into the multipart object.Not Zed2000-11-0410-33/+249
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-04 Not Zed <NotZed@HelixCode.com> * camel-mime-part-utils.c (camel_mime_part_construct_content_from_parser): Set the preface/postface from the parser into the multipart object. * camel-multipart.c (camel_multipart_set_postface): Function to set the postface text on a multipart. (camel_multipart_set_preface): Similarly for preface text. * camel-mime-parser.c (folder_scan_content): If we scan until a boundary, then we do not include the \n that starts the boundary line in the content. (struct _header_scan_stack): Added a ByteArray to store the multipart pre/post-text as we're scanning. (folder_pull_part): Free pre/posttext if they are allocated. (folder_scan_step): Build into the pre/posttext arrays as we encounter data. (camel_mime_parser_preface): REturn the multipart preface text, if there is any scanned. (camel_mime_parser_postface): Likewise for postface text. (byte_array_to_string): helper function for above. * providers/mbox/camel-mbox-folder.c (mbox_append_message): Change the from line to be "\nFrom ..." always, so no need to check/append a \n to messages. (mbox_append_message): Open the output stream with append mode [assuming this is more efficient than seeking to the end] And dont prepend \n on the From line if its the first in the mbox. (mbox_append_message): Pass the offset of the real start of the "From " line when we perform the update (which may != 'seek') * camel-mime-filter-charset.c (complete): Removed the terminating NUL 'fix'. * camel-stream-filter.c (do_read): Added some debug. (do_flush): And here. (do_write): And here too. (do_write): ARGH!!! ARGH! Ok, so the filter stream was writing a different number of bytes than the requester was asking it to write (because of filtering, of course!). So instead of returning the true number of written bytes, we'll return what they asked us to write - unless there is an error in which case we return -1. * camel-mime-utils.c (base64_encode_close): Sigh, forgot to make it unsigned. I think this is actually a gcc bug as (48 >> 2) somehow ended up negative, when it obviously should not, even if the data load was signed. svn path=/trunk/; revision=6388
* Undo my incorrect fix - I misunderstood danw - sorry!Jeffrey Stedfast2000-11-042-26/+9
| | | | | | | | | 2000-11-03 Jeffrey Stedfast <fejj@helixcode.com> * camel-url.c: Undo my incorrect fix - I misunderstood danw - sorry! svn path=/trunk/; revision=6386
* Unbreak this.Dan Winship2000-11-042-2/+7
| | | | | | | * providers/pop3/camel-pop3-store.c (camel_pop3_store_expunge): Unbreak this. svn path=/trunk/; revision=6381
* If show_pass, then base64 the password before writing it to the outputJeffrey Stedfast2000-11-042-6/+41
| | | | | | | | | | | 2000-11-03 Jeffrey Stedfast <fejj@helixcode.com> * camel-url.c (camel_url_to_string): If show_pass, then base64 the password before writing it to the output string. (camel_url_new): Assume password has been base64 encoded and decode accordingly. svn path=/trunk/; revision=6374
* fix bug in previousDan Winship2000-11-041-3/+1
| | | | svn path=/trunk/; revision=6373
* Add an "url_flags" field to CamelProvider. Move the CAMEL_SERVICE_URL_*Dan Winship2000-11-0419-79/+79
| | | | | | | | | | | | | | | | | | | | * camel-provider.h: Add an "url_flags" field to CamelProvider. Move the CAMEL_SERVICE_URL_* defines here and remove the SERVICE_ part of the name. * camel-service.h: Remove CAMEL_SERVICE_URL_* flags and service->url_flags field. * camel-service.c (check_url, get_path): Get URL flags from service->provider, update for changed flag names. * providers/*/camel-*-provider.c: Add URL flags to provider structures. * providers/*/camel-*-{store,transport}.c, camel-remote-store.c: Remove service->url_flags initialization. svn path=/trunk/; revision=6370
* Quote foldernames when sending to the IMAP server because the folder nameJeffrey Stedfast2000-11-022-1/+7
| | | | | | | | | | 2000-11-02 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (get_folder_info): Quote foldernames when sending to the IMAP server because the folder name might contain spaces. svn path=/trunk/; revision=6344
* Merged in camel-incremental-branch.Not Zed2000-11-0213-107/+532
| | | | | | | | 2000-11-02 Not Zed <NotZed@HelixCode.com> * Merged in camel-incremental-branch. svn path=/trunk/; revision=6336
* Remove old subbed folders from hash table after freeing them.Dan Winship2000-11-022-3/+14
| | | | | | | * providers/imap/camel-imap-store.c (get_folder_info): Remove old subbed folders from hash table after freeing them. svn path=/trunk/; revision=6335
* Deal correctly with namespace == ""Dan Winship2000-11-022-1/+6
| | | | | | | * providers/imap/camel-imap-folder.c (imap_get_full_name): Deal correctly with namespace == "" svn path=/trunk/; revision=6322
* calendar: made all gui show localizedGediminas Paulauskas2000-11-013-209/+696
| | | | | | | camel: updated charset info from newest libunicode po: updated Lithuanian translation svn path=/trunk/; revision=6308
* Add a new argument, clean, that says whether or not to try to disconnectDan Winship2000-11-018-80/+62
| | | | | | | | | | | | | | | | | | * camel-service.c (service_disconnect): Add a new argument, clean, that says whether or not to try to disconnect cleanly. * camel-remote-store.c (remote_send_string, remote_send_stream, remote_recv_line): disconnect uncleanly on failure to prevent infinite loops when providers would normally send commands from disconnect(). Remove some unneeded CamelException goo. * providers/smtp/camel-smtp-transport.c (smtp_disconnect): * providers/pop3/camel-pop3-store.c (pop3_disconnect): * providers/nntp/camel-nntp-store.c (nntp_store_disconnect): * providers/imap/camel-imap-store.c (imap_disconnect): Don't send QUIT/LOGOUT if !clean. svn path=/trunk/; revision=6303
* Camel IMAP authentication includes (forgotten in last commit)Dan Winship2000-10-311-0/+39
| | | | svn path=/trunk/; revision=6275
* New file with code for IMAP authentication mechanisms. (Currently justDan Winship2000-10-315-84/+384
| | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-auth.c: New file with code for IMAP authentication mechanisms. (Currently just krb4, and without integrity/privacy protection). * providers/imap/Makefile.am: Add camel-imap-auth.[ch] and krb4 CFLAGS/LDFLAGS * providers/imap/camel-imap-store.c (connect_to_server): Split out from imap_connect. Just does the basic connect and CAPABILITY check. Redo the CAPABILITY code more robustly. (query_auth_types_connected): Do this right rather than punting to query_auth_types_generic. Check for KERBEROS_V4 if compiled with krb4 support. (query_auth_types_generic): Mention KERBEROS_V4 if compiled with krb4 support. (imap_connect): Use connect_to_server(). svn path=/trunk/; revision=6272
* Take an additional argument, "break_lines", saying whether or not to addDan Winship2000-10-314-10/+11
| | | | | | | | | | | | * camel-mime-utils.c (base64_encode_step, base64_encode_close): Take an additional argument, "break_lines", saying whether or not to add '\n's to the output. * camel-multipart.c (set_boundary): * camel-mime-filter-basic.c (filter, complete): Update for base64 api change. svn path=/trunk/; revision=6271
* Improved IMAP namespace handling: leave the namespace in theDan Winship2000-10-309-274/+343
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | folder names rather than constantly prepending it and stripping it off. Also some subscription fixes. * camel-store.c (camel_folder_info_build): Fix for the case where @top isn't in @folders. * providers/imap/camel-imap-folder.c (camel_imap_folder_new): Add a "short_name" argument rather than figuring it out ourselves. (imap_get_full_name): Implementation of CamelFolder::get_full_name that strips off namespace so the user doesn't have to see it. (imap_append_message, imap_copy_message_to, imap_move_message_to): Use folder->full_name rather than calling camel_imap_store_get_folder_path. * providers/imap/camel-imap-utils.c (imap_parse_list_response): Update this: make @flags a bitmask and @sep a char rather than a string. Make all of the out arguments optional. Handle literals in the server response. * providers/imap/camel-imap-store.c (imap_connect): Do a better job of getting the correct dir_sep for the namespace we're using. Construct a base_url here that will be used by get_folder_info. (camel_imap_store_folder_path): Removed (imap_folder_exists): Add an argument to return the short name of the folder (parsed out of the LIST response). Update for imap_parse_list_response change. (get_folder): Update for the various other changes. (get_folder_info): Update for the various other changes. Be more consistent about the returned layout: put everything underneath the "namespace" directory, including INBOX, even if it doesn't belong there. Don't destroy the list of subscribed folders until we've actually gotten the new list. (folder_subscribed, subscribe_folder, unsubscribe_folder): Use folder_name directly rather than camel_imap_store_folder_Path. * providers/imap/camel-imap-command.c (camel_imap_command): Update for folder name changes. svn path=/trunk/; revision=6256
* Remove md5-utils.h include since it's not part of Camel any more.Dan Winship2000-10-306-12/+29
| | | | | | | | | | | | | | | | | | | | * camel.h: Remove md5-utils.h include since it's not part of Camel any more. * camel-charset-map.c: Kill some warnings. * providers/nntp/camel-nntp-grouplist.c (camel_nntp_get_grouplist_from_file, camel_nntp_grouplist_save): Clean up warnings about time_t casts. * providers/smtp/camel-smtp-transport.c: Remove unused md5-utils.h include. * providers/pop3/camel-pop3-store.c: Undefine the "_" macro defined by krb4's des.h when compiling with krb support. Fix md5-utils.h include. svn path=/trunk/; revision=6253
* Remove previous comment about Outlook brokenness, since it turns out theDan Winship2000-10-282-7/+3
| | | | | | | brokenness was actually somewhere else. (Still in Outlook, just not in the part of Outlook I was told it was.) svn path=/trunk/; revision=6241
* Work around Outlook brokenness in iMIP parsing by only quotingDan Winship2000-10-282-2/+24
| | | | | | | | * camel-mime-utils.c (header_param_list_format_append): Work around Outlook brokenness in iMIP parsing by only quoting Content-type parameters when the quoting is mandatory. svn path=/trunk/; revision=6237
* build md5-utils72000-10-286-449/+22
| | | | | | | | | | | | | | | | | | | | | | | | 2000-10-27 <jpr@helixcode.com> * Makefile.am: build md5-utils * md5-utils.c: Make part of util, get rid of camel stream util function include string.h * md5-utils.h: ditto 2000-10-27 <jpr@helixcode.com> * providers/pop3/Makefile.am: Tidy up build * providers/smtp/Makefile.am: ditto * Makefile.am: Move md5-utils.[hc] to e-util because the addressbook is going to use md5 hashes for pilot syncing. Maybe the calendar conduits as well because this is a good idea Chris had. svn path=/trunk/; revision=6234
* Add newline to kill warnings.Kjartan Maraas2000-10-262-1/+5
| | | | | | | | 2000-10-26 Kjartan Maraas <kmaraas@gnome.org> * camel-exceptions-list.def: Add newline to kill warnings. svn path=/trunk/; revision=6183
* Fix folder listing code infinite loop.Dan Winship2000-10-262-1/+4
| | | | | | | * providers/imap/camel-imap-store.c (get_folder_info): Fix folder listing code infinite loop. svn path=/trunk/; revision=6178
* Add a "parent" field to CamelFolderInfo.Dan Winship2000-10-255-17/+47
| | | | | | | | | | | | | | | | | | | | | | * camel-store.h: Add a "parent" field to CamelFolderInfo. * camel-store.c (camel_folder_info_build): Deal with "parent" (camel_store_folder_subscribed, camel_store_subscribe_folder, camel_store_unsubscribe_folder): Add g_return_if_fails checking that the folder supports subscriptions. * providers/imap/camel-imap-store.c (folder_subscribed, subscribe_folder, unsubscribe_folder): Remove "+ 1"s since the mail subscribe UI won't prepend / to the folder names now. (get_folder_info): Clear the "parent" field of the folderinfos when removing an empty top level. * providers/nntp/camel-nntp-store.c (nntp_store_folder_subscribed, nntp_store_subscribe_folder, nntp_store_unsubscribe_folder): Remove "+ 1"s since the mail subscribe UI won't prepend / to the folder names now. svn path=/trunk/; revision=6167
* add subscribed_folders.Chris Toshok2000-10-253-4/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-24 Chris Toshok <toshok@helixcode.com> * providers/imap/camel-imap-store.h: add subscribed_folders. * providers/imap/camel-imap-store.c (camel_imap_store_class_init): fill in vtable entries for subscription functions. (camel_imap_store_finalize): new function, so we can free up our subscribed_folders hashtable. (camel_imap_store_init): set CAMEL_STORE_SUBSCRIPTIONS in the CamelStore flags, and create our subscribed_folders hashtable. (camel_imap_store_get_type): camel_imap_store_finalize is our finalize function. (get_folder_info): if we're looking at subscribed_only, clear out the subscribed_folders hashtable, use LSUB instead of LIST, and insert folder paths (prepended by their namespace if there is one) into subscribed_folders. INBOX subscription support needs work, since we always show it, regardless of it's subscribed state. (folder_subscribed): new function. just look up the folder_path in the hashtable. (subscribe_folder): new function. use the imap SUBSCRIBE command, and if successful add it to the hashtable. (unsubscribe_folder): new function. use the imap UNSUBSCRIBE command, and if successful remove it from the hashtable. svn path=/trunk/; revision=6157
* add a missing #includeDan Winship2000-10-251-0/+1
| | | | svn path=/trunk/; revision=6154
* Fill in the message_count and unread_message_count flags (if !fast).Dan Winship2000-10-252-5/+39
| | | | | | | * providers/imap/camel-imap-store.c (get_folder_info): Fill in the message_count and unread_message_count flags (if !fast). svn path=/trunk/; revision=6151
* lots of i18n fixesDan Winship2000-10-2432-235/+216
| | | | svn path=/trunk/; revision=6143
* add camel-nntp-types.h.Chris Toshok2000-10-242-1/+7
| | | | | | | | | 2000-10-23 Chris Toshok <toshok@helixcode.com> * providers/nntp/Makefile.am (libcamelnntpinclude_HEADERS): add camel-nntp-types.h. svn path=/trunk/; revision=6133
* Fix a "how could this have been working before" memory overrun bug foundDan Winship2000-10-242-0/+7
| | | | | | | | * providers/imap/camel-imap-command.c (imap_read_untagged): Fix a "how could this have been working before" memory overrun bug found by Vlad. svn path=/trunk/; revision=6129
* These should have gone away a long time ago.Dan Winship2000-10-245-834/+5
| | | | | | | * camel-op-queue.[ch], camel-thread-proxy.[ch]: These should have gone away a long time ago. svn path=/trunk/; revision=6115
* re-enable the nntp provider.Chris Toshok2000-10-212-1/+5
| | | | | | | | 2000-10-20 Chris Toshok <toshok@helixcode.com> * providers/Makefile.am (SUBDIRS): re-enable the nntp provider. svn path=/trunk/; revision=6090
* add function to build a tree from the nntp group names (using '.' as aChris Toshok2000-10-212-41/+149
| | | | | | | | | | | | | | | 2000-10-20 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (build_folder_info): add function to build a tree from the nntp group names (using '.' as a heirarchy separator.) #ifdefed INFO_AS_TREE only. (build_folder_info_from_grouplist): if INFO_AS_TREE is selected, call build_folder_info instead of appending a new CamelFolderInfo to our list. (ensure_news_dir_exists): use e_mkdir_hier instead of failing if a parent directory (~/evolution/news generally) isn't there. svn path=/trunk/; revision=6089
* #include <sys/types.h> before <regex.h>Chris Toshok2000-10-202-0/+5
| | | | | | | | 2000-10-19 Chris Toshok <toshok@helixcode.com> * camel-folder-search.c: #include <sys/types.h> before <regex.h> svn path=/trunk/; revision=6072
* Fix a bug with "INBOX" (or anything else with NIL hierarchy separator) asDan Winship2000-10-202-1/+5
| | | | | | | | * providers/imap/camel-imap-utils.c (imap_parse_list_response): Fix a bug with "INBOX" (or anything else with NIL hierarchy separator) as the namespace. svn path=/trunk/; revision=6065
* Emit message_changed and folder_changed as appropriate.Dan Winship2000-10-202-2/+25
| | | | | | | * providers/imap/camel-imap-folder.c (imap_refresh_info): Emit message_changed and folder_changed as appropriate. svn path=/trunk/; revision=6064
* Update comment here so refresh_info isn't just for reconnects any more.Dan Winship2000-10-205-61/+64
| | | | | | | | | | | | | | | | | | | | | | * camel-folder.c (camel_folder_refresh_info): Update comment here so refresh_info isn't just for reconnects any more. Make the default implementation a no-op rather than an error. * providers/nntp/camel-nntp-folder.c: Move refresh_info impl into camel_nntp_folder_new, since it would have leaked memory and not done anything useful if it was called later. * providers/mbox/camel-mbox-folder.c: Remove no-longer-necessary refresh_info impl. * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): Update imap_folder->exists, but don't actually load the new messages. This is a temporary workaround to deal with the IMAP provider stealing the message list focus at annoying times. (imap_copy_message_to, imap_move_message_to): Emit a folder_changed by hand, for now. svn path=/trunk/; revision=6046
* Build fixes from Jacob, same as the other branch.Ettore Perazzoli2000-10-203-0/+11
| | | | svn path=/trunk/; revision=6035
* The correct fix this time - the description should be encoded here and notJeffrey Stedfast2000-10-192-1/+10
| | | | | | | | | | 2000-10-18 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-part.c (camel_mime_part_set_description): The correct fix this time - the description should be encoded here and not in the camel-medium layer. svn path=/trunk/; revision=6008
* Initialize the outbuf to be empty before calling unicode_iconv on it.Ettore Perazzoli2000-10-192-0/+8
| | | | | | This fixes a problem with duplicate message bodies on my machine. svn path=/trunk/; revision=5998
* No, we must not encode the headers here. These interfaces ARE rawNot Zed2000-10-1821-144/+348
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-18 Not Zed <NotZed@HelixCode.com> * camel-mime-part.c (add_header): No, we must not encode the headers here. These interfaces ARE raw interfaces as they are defined in camel_medium. Also removed a bogus/meaningless FIXME. (set_header): Likewise here, we must not. (process_header): Removed another bogus comment. * camel-object.c (shared_is_of_type): Comment out the spitting of a big warning when we're trying to determine types from code. * providers/mbox/camel-mbox-summary.c (message_info_new_from_parser): Only call ibex funcitons if we have an index. * providers/mh/camel-mh-summary.c (camel_mh_summary_add): Only call ibex functions if we have an index. (remove_summary): Likewise. (camel_mh_summary_check): Likewise. * providers/nntp/camel-nntp-store.c (nntp_store_get_folder): get_folder -> flags argument. * providers/vee/camel-vee-store.c (vee_get_folder): create->flags. * providers/pop3/camel-pop3-store.c (get_folder): Changed create -> flags. * providers/imap/camel-imap-store.c (get_folder): Added flags argument. * providers/mh/camel-mh-folder.c (camel_mh_folder_new): Added flags argument, and fixed code appropriately. * providers/mh/camel-mh-store.c (get_folder): Added flags argument. * camel-folder-search.c (message_body_contains): Perform a regex match on the contents of messages. This wont quite work yet as message contents are encoded when written to a stream. (build_match_regex): Converts a number of strings into a regex matching pattern, escaping special chars. (match_message): match a single message from a folder, by uid. Slow. (search_body_contains): Changed to support matching where no index is supplied. Matches are performed by retrieving message contents, etc. () WTF? camel should not be including any widget headers. * providers/mbox/camel-mbox-folder.c (camel_mbox_folder_new): Added flags argument. (mbox_refresh_info): Changed into a NOP, the refresh info code moved into the new function. (camel_mbox_folder_new): If we have an index requested, build one, otherwise, remove an old one, or just dont do anything. * providers/mbox/camel-mbox-store.c (get_folder): Changed create to flags, changed code to suit. * camel-store.c (camel_store_get_folder): Changed create to flags. (get_folder_internal): And here. (get_folder): And here too. * camel-store.h (camel_store_get_folder): Change the create argument to be a flags argument. svn path=/trunk/; revision=5978
* (camel_imap_folder_new): Move the summary creation to after theDan Winship2000-10-182-9/+12
| | | | | | | folder selection again, since it depends on the uidvalidity having been set. svn path=/trunk/; revision=5976
* Remove cached info at the end of the summary when the folder shrinksDan Winship2000-10-183-11/+23
| | | | | | | | | | | * providers/imap/camel-imap-folder.c (imap_refresh_info): Remove cached info at the end of the summary when the folder shrinks between sessions. Also remove an untrue comment. * providers/imap/camel-imap-store.c (get_folder): Fix up summary_file to not include the namespace twice. svn path=/trunk/; revision=5974
* Encode the header value. (add_header): Same.Jeffrey Stedfast2000-10-182-12/+25
| | | | | | | | | 2000-10-17 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-part.c (set_header): Encode the header value. (add_header): Same. svn path=/trunk/; revision=5970
* Added some malloc check debugging stuff.Not Zed2000-10-174-18/+81
| | | | | | | | | | | | | | | | | | | | | 2000-10-17 Not Zed <NotZed@HelixCode.com> * camel-mime-filter.c: Added some malloc check debugging stuff. * camel-mime-parser.c (struct _header_scan_state): Removed top_part, top_start, and pending. I can't even remember why they were there, and they're not used anymore. * camel-mime-filter-basic.c (filter): Forgot to up the space here too. 2000-10-14 Not Zed <NotZed@HelixCode.com> * camel-mime-filter-basic.c (complete): Ok, so we hit a fixme, 3x just wasn't enough for some sequences. svn path=/trunk/; revision=5962
* Don't imap_next_word(respbuf + 2), instead use imap_next_word(respbuf) orJeffrey Stedfast2000-10-172-1/+8
| | | | | | | | | | | 2000-10-16 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-command.c (imap_read_response): Don't imap_next_word(respbuf + 2), instead use imap_next_word(respbuf) or else we'll skip over the second token. svn path=/trunk/; revision=5961
* Don't free 'resp' as it doesn't point to the beginning of the allocatedJeffrey Stedfast2000-10-172-14/+26
| | | | | | | | | | | | | | | | | 2000-10-16 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-command.c (camel_imap_response_extract): Don't free 'resp' as it doesn't point to the beginning of the allocated data, instead free response->untagged->pdata[i]. Also, if '*resp' is equal to a space character, then set resp = imap_next_word (resp) rather than expecting resp++ to work (there's a list broken IMAP daemons that like to put extra spaces between tokens). (imap_read_response): Don't expect 'respbuf+2' to be where the untagged number response to start (see above fix for an explanation). svn path=/trunk/; revision=5960
* when using the construct (flags & CAMEL_SERVICE_URL_NEED_*) make sure toChris Toshok2000-10-172-8/+18
| | | | | | | | | | | 2000-10-16 Chris Toshok <toshok@helixcode.com> * camel-service.c (get_path): when using the construct (flags & CAMEL_SERVICE_URL_NEED_*) make sure to do ((flags & CAMEL_SERVICE_URL_NEED_*) == CAMEL_SERVICE_URL_NEED_*) (check_url): same. svn path=/trunk/; revision=5951
* Only send the LOGOUT command if the store is connected. (imap_connect):Jeffrey Stedfast2000-10-174-12/+47
| | | | | | | | | | | | | | | | | | | 2000-10-16 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (imap_disconnect): Only send the LOGOUT command if the store is connected. (imap_connect): Set the 'connected' state to TRUE when we successfully connect. (get_folder_info): if (!topfi), 'topfi' was allocated but then 'fi' was set. I think Dan meant to set topfi since fi is an uninitialized value at this point. * providers/imap/camel-imap-command.c (imap_read_response): Check for the untagged BYE response and set the 'connected' state to FALSE if we receive the BYE response. Return NULL if we get a BYE response. svn path=/trunk/; revision=5944
* Deal with the possibility of not getting a LIST response back for the topDan Winship2000-10-172-12/+20
| | | | | | | | * providers/imap/camel-imap-store.c (get_folder_info): Deal with the possibility of not getting a LIST response back for the top level. svn path=/trunk/; revision=5941
* Simple subclass of CamelFolderSummary that also keeps a UIDVALIDITY valueDan Winship2000-10-1313-541/+609
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-summary.c: Simple subclass of CamelFolderSummary that also keeps a UIDVALIDITY value (and doesn't, for the moment, build content info). * providers/imap/camel-imap-folder.c: (various): Use a CamelImapSummary to store/fetch summary info. (camel_imap_folder_new): Take a path to a file to use for the summary. Set the folder's permanent_flags correctly according to the server response. Read in the summary (checking the UIDVALIDITY) and update it if it's out of date. (imap_refresh_info): Just fetch UIDs and flags. If the UIDs all match, update the flags as needed and be done with it. Otherwise, delete messages that have been expunged from the server and fetch full summary info for any new messages. (imap_sync): Save the summary to disk. (imap_update_summary): Renamed from imap_get_summary_internal. Can now be told to get summary for only a subset of messages. Use camel-mime-utils functions rather than rolling our own header parsing. (imap_get_message_info_internal): Merged into imap_update_summary. (imap_set_message_flags): Don't marked the message FOLDER_FLAGGED if we're not actually changing the value of any of the flags. (camel_imap_folder_changed): Deal with EXISTS rather than RECENT. * providers/imap/camel-imap-store.c (imap_connect): Call camel_session_get_storage_path and save the value. (get_folder): Create a local directory to store summary information and pass a summary file name to camel_imap_folder_new. Don't call camel_folder_refresh_info from here any more since camel_imap_folder_new does it again. * providers/imap/camel-imap-command.c (camel_imap_command): Add a special case to this to make it possible to get the repsonses from a SELECT and still have store->current_folder be updated correctly. (imap_read_response): parse EXISTS rather than RECENT * camel-session.c (camel_session_get_storage_path): Use e_mkdir_hier. * camel-folder-summary.c (camel_folder_summary_remove_index): New function. * camel-mime-utils.c (header_raw_append_parse): fix this. (camel-mime-parser.c doesn't use this code because of the MEMPOOL optimization, so nothing was ever actually calling it before.) svn path=/trunk/; revision=5891
* Removed temp_message_buffer, and content_input_stream fields which seem toNot Zed2000-10-128-27/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-11 Not Zed <NotZed@HelixCode.com> * camel-mime-part.h (struct _CamelMimePart): Removed temp_message_buffer, and content_input_stream fields which seem to have come from nowhere, and are unused. * camel-mime-utils.c: Added a note about touching this file. Nobody is to touch it without asking me first. That goes for you too Jeff. (header_decode_text): In what way is this broken? 2000-10-10 Not Zed <NotZed@HelixCode.com> * providers/imap/camel-imap-folder.c (imap_get_summary_internal): Fix camel_summary_* function rename (imap_get_message_info_internal): Likewise. * camel-mime-parser.c (camel_mime_parser_finalise): Fixed a spelling mistake. * camel-folder-summary.c (camel_summary_format_address): Uh, why do we encode and then decode here ... sigh. This is not the way to fix this. (camel_folder_summary_format_address): Renamed to a proper name, this was only supposed to be a private function. (camel_folder_summary_format_string): Likewise. Oh i see why it was made public, code reuse by cut & paste. Joy. svn path=/trunk/; revision=5881
* remove the leading '/'. (nntp_store_subscribe_folder): same.Chris Toshok2000-10-122-3/+9
| | | | | | | | | | 2000-10-11 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (nntp_store_unsubscribe_folder): remove the leading '/'. (nntp_store_subscribe_folder): same. (nntp_store_folder_subscribed): same. svn path=/trunk/; revision=5868
* Quote the mailbox name as it may contain spaces. (imap_copy_message_to):Jeffrey Stedfast2000-10-122-2/+8
| | | | | | | | | | 2000-10-11 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_move_message_to): Quote the mailbox name as it may contain spaces. (imap_copy_message_to): Same. svn path=/trunk/; revision=5853
* fill in message_count and unread_message_count properly.Chris Toshok2000-10-115-30/+69
| | | | | | | | | | | | | | | | | | | 2000-10-10 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (build_folder_info_from_grouplist): fill in message_count and unread_message_count properly. * providers/nntp/camel-nntp-newsrc.h: reformat. * providers/nntp/camel-nntp-grouplist.c (camel_nntp_get_grouplist_from_file): remove spew. * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_group_get_num_articles_read): new function. (camel_nntp_newsrc_group_get_highest_article_read): robustification. svn path=/trunk/; revision=5832
* Un-rasterize my changelog entryJoe Shaw2000-10-111-1/+1
| | | | | | No, I am not artifically inflating my commit numbers. svn path=/trunk/; revision=5824
* Check before deferencing the sep pointer.Joe Shaw2000-10-112-1/+8
| | | | | | | | | | 2000-10-10 Joe Shaw <joe@helixcode.com> * providers/imap/camel-imap-store.c (parse_list_response_as_folder_info): Check before deferencing the sep pointer. svn path=/trunk/; revision=5822
* teach camel about "its" vs. "it's"Jacob "Ulysses" Berkman2000-10-115-8/+12
| | | | | | | | 2000-10-10 Jacob "Ulysses" Berkman <jacob@helixcode.com> * camel-*.c: teach camel about "its" vs. "it's" svn path=/trunk/; revision=5819
* write out the newsrc. (nntp_store_get_name): if @brief, just return host.Chris Toshok2000-10-103-57/+95
| | | | | | | | | | | | | 2000-10-09 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (finalize): write out the newsrc. (nntp_store_get_name): if @brief, just return host. * providers/nntp/camel-nntp-newsrc.c: robustification and bug fixes. svn path=/trunk/; revision=5808
* Issue a warning if h->value is NULL.Miguel de Icaza2000-10-081-1/+9
| | | | | | | | | 2000-10-08 Miguel de Icaza <miguel@helixcode.com> * camel-mime-part.c (write_to_stream): Issue a warning if h->value is NULL. svn path=/trunk/; revision=5785
* Decode the resulting string.Jeffrey Stedfast2000-10-072-6/+15
| | | | | | | | | 2000-10-06 Jeffrey Stedfast <fejj@helixcode.com> * camel-folder-summary.c (camel_summary_format_address): Decode the resulting string. svn path=/trunk/; revision=5773
* add camel-nntp-grouplist.h (libcamelnntp_la_SOURCES): addChris Toshok2000-10-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-06 Chris Toshok <toshok@helixcode.com> * providers/nntp/Makefile.am (libcamelnntpinclude_HEADERS): add camel-nntp-grouplist.h (libcamelnntp_la_SOURCES): add camel-nntp-grouplist.c * providers/nntp/camel-nntp-provider.c: add our own hash functions for nntp urls. * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_group_is_subscribed): new function. (camel_nntp_newsrc_subscribe_group): new function. (camel_nntp_newsrc_unsubscribe_group): new function. * providers/nntp/camel-nntp-newsrc.h: add prototypes for _group_is_subscribed, _subscribe_group, and _unsubscribe_group. * providers/nntp/camel-nntp-store.c (build_folder_info_from_grouplist): new function. (nntp_store_get_folder_info): add subscribed_only_parameter. if it's FALSE, load the grouplist and call build_folder_info_from_grouplist. (nntp_store_folder_subscribed): implement. (nntp_store_subscribe_folder): implement. (nntp_store_unsubscribe_folder): implement. (camel_nntp_store_init): add CAMEL_STORE_SUBSCRIPTIONS to the store's flags. * providers/mh/camel-mh-store.c (get_folder_info): add subscribed_only parameter. * providers/mbox/camel-mbox-store.c (get_folder_info): add subscribed_only parameter. * providers/imap/camel-imap-store.c (get_folder_info): add subscribed_only parameter. * camel-store.c (camel_store_supports_subscriptions): new function. (camel_store_folder_subscribed): new function. (camel_store_subscribe_folder): new function. (camel_store_unsubscribe_folder): new function. * camel-store.h: add prototypes and virtual functions for the subscribe implementation. also, add a subscribed_only argument to camel_store_get_folder_info. svn path=/trunk/; revision=5769
* new file.Chris Toshok2000-10-074-0/+309
| | | | | | | | | | | | 2000-10-06 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-grouplist.c: new file. * providers/nntp/camel-nntp-grouplist.h: new file. * providers/nntp/camel-nntp-types.h: new file. svn path=/trunk/; revision=5767
* Fix so that we don't encode every single char in the word. Also, do weJeffrey Stedfast2000-10-072-2/+3
| | | | | | | | | | | 2000-10-06 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-utils.c (quoted_encode): Fix so that we don't encode every single char in the word. Also, do we need a safemask? I don't see why we would. (header_encode_string): Don't strip off the last char!! svn path=/trunk/; revision=5766
* Fix so that we don't encode every single char in the word. Also, do weJeffrey Stedfast2000-10-072-12/+19
| | | | | | | | | | 2000-10-06 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-utils.c (quoted_encode): Fix so that we don't encode every single char in the word. Also, do we need a safemask? I don't see why we would. svn path=/trunk/; revision=5765
* Don't compile the NNTP provider as it currently doesn't build becauseEttore Perazzoli2000-10-071-1/+1
| | | | | | of missing `camel-nntp-types.h'. svn path=/trunk/; revision=5762
* add camel-nntp-grouplist.h (libcamelnntp_la_SOURCES): addChris Toshok2000-10-0611-28/+361
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-06 Chris Toshok <toshok@helixcode.com> * providers/nntp/Makefile.am (libcamelnntpinclude_HEADERS): add camel-nntp-grouplist.h (libcamelnntp_la_SOURCES): add camel-nntp-grouplist.c * providers/nntp/camel-nntp-provider.c: add our own hash functions for nntp urls. * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_group_is_subscribed): new function. (camel_nntp_newsrc_subscribe_group): new function. (camel_nntp_newsrc_unsubscribe_group): new function. * providers/nntp/camel-nntp-newsrc.h: add prototypes for _group_is_subscribed, _subscribe_group, and _unsubscribe_group. * providers/nntp/camel-nntp-store.c (build_folder_info_from_grouplist): new function. (nntp_store_get_folder_info): add subscribed_only_parameter. if it's FALSE, load the grouplist and call build_folder_info_from_grouplist. (nntp_store_folder_subscribed): implement. (nntp_store_subscribe_folder): implement. (nntp_store_unsubscribe_folder): implement. (camel_nntp_store_init): add CAMEL_STORE_SUBSCRIPTIONS to the store's flags. * providers/mh/camel-mh-store.c (get_folder_info): add subscribed_only parameter. * providers/mbox/camel-mbox-store.c (get_folder_info): add subscribed_only parameter. * providers/imap/camel-imap-store.c (get_folder_info): add subscribed_only parameter. * camel-store.c (camel_store_supports_subscriptions): new function. (camel_store_folder_subscribed): new function. (camel_store_subscribe_folder): new function. (camel_store_unsubscribe_folder): new function. * camel-store.h: add prototypes and virtual functions for the subscribe implementation. also, add a subscribed_only argument to camel_store_get_folder_info. svn path=/trunk/; revision=5760
* Encode the name part of the address and don't quote the name.Jeffrey Stedfast2000-10-062-14/+78
| | | | | | | | | | | 2000-10-05 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-utils.c (header_address_list_format_append): Encode the name part of the address and don't quote the name. (header_decode_text): Rewrote from scratch, the old code was badly broken. svn path=/trunk/; revision=5758
* Use the camel_address_encode function again.Jeffrey Stedfast2000-10-062-4/+26
| | | | | | | | | | 2000-10-05 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-message.c (camel_mime_message_set_reply_to): Use the camel_address_encode function again. (camel_mime_message_set_from): Same. svn path=/trunk/; revision=5756
* Modified to not encode space chars in the middle of a line. (isblank): NewJeffrey Stedfast2000-10-063-40/+53
| | | | | | | | | | | | | | | 2000-10-05 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-utils.c (quoted_encode_step): Modified to not encode space chars in the middle of a line. (isblank): New macro if we're not on a system with the GNU isblank extension. * camel-mime-message.c (camel_mime_message_set_from): Reversed my changes, don't header_encode_phrase - it generates broken headers. (camel_mime_message_set_reply_to): Same. svn path=/trunk/; revision=5747
* revert to old method (only use XOVER if OVER is supported.)Chris Toshok2000-10-053-14/+34
| | | | | | | | | | | | | | 2000-10-04 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-utils.c (camel_nntp_get_headers): revert to old method (only use XOVER if OVER is supported.) * providers/nntp/camel-nntp-store.c (camel_nntp_store_get_overview_fmt): handle the case where the OVER extension isn't listed but LIST OVERVIEW.FMT works (again, INN 2.2). enable the OVER extension in this case. svn path=/trunk/; revision=5739
* return a gboolean so we can tell if this command worked. we can't key offChris Toshok2000-10-052-8/+20
| | | | | | | | | | | | | | | 2000-10-04 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-utils.c (get_XOVER_headers): return a gboolean so we can tell if this command worked. we can't key off the OVER extension being present because at least one server (INN 2.2) doesn't report the OVER extension but implements the XOVER command. This could of course just be because I'm a loser for thinking they were related in the first place. (camel_nntp_get_headers): always try XOVER first, and if it fails revert to the slow method. svn path=/trunk/; revision=5723
* Fix a case where a variable was free'd and then possibly used in an errorDan Winship2000-10-052-2/+7
| | | | | | | * providers/mbox/camel-mbox-store.c (get_folder): Fix a case where a variable was free'd and then possibly used in an error message. svn path=/trunk/; revision=5722
* news: -> nntp:.Chris Toshok2000-10-052-23/+7
| | | | | | | | | 2000-10-04 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-provider.c (camel_provider_module_init): news: -> nntp:. svn path=/trunk/; revision=5720
* use "nntp:" instead of "news:" since "news:" urls aren't supposed to haveChris Toshok2000-10-052-2/+14
| | | | | | | | | | | 2000-10-04 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (nntp_store_get_folder_info): use "nntp:" instead of "news:" since "news:" urls aren't supposed to have host/user/port info in them. also, if there's a user defined in the url, put it in the urls for our folders. svn path=/trunk/; revision=5717
* borrow some code from the imap provider to query the user for theirChris Toshok2000-10-053-30/+123
| | | | | | | | | | | | | | | | | | 2000-10-04 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-auth.c (camel_nntp_auth_authenticate): borrow some code from the imap provider to query the user for their password, and pass the user/passwd to nntp. be extra paranoid and zero out the password before freeing it. * providers/nntp/camel-nntp-store.c (camel_nntp_store_init): add ALLOW_USER/ALLOW_PASSWORD/ALLOW_AUTH to the url flags. (nntp_store_query_auth_types_generic): return our list of auth_types. (nntp_store_query_auth_types_connected): broken, return same as in query_auth_types_generic. svn path=/trunk/; revision=5716
* IMAP4 (pre-rev1) doesn't support the 'LIST "" ""' idiom, so don't use it.Dan Winship2000-10-052-19/+34
| | | | | | | | * providers/imap/camel-imap-store.c (imap_connect): IMAP4 (pre-rev1) doesn't support the 'LIST "" ""' idiom, so don't use it. Just assume the dir_sep is '/'. Shrug. svn path=/trunk/; revision=5714
* Use header_encode_phrase instead. (camel_mime_message_set_from): Same.Jeffrey Stedfast2000-10-052-12/+8
| | | | | | | | | | 2000-10-04 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-message.c (camel_mime_message_set_reply_to): Use header_encode_phrase instead. (camel_mime_message_set_from): Same. svn path=/trunk/; revision=5710
* Handle the case where ct != NULL, but type and subtype are, and also matchNot Zed2000-10-044-14/+59
| | | | | | | | | | | | | | | | | | | | | | 2000-10-04 Not Zed <NotZed@HelixCode.com> * camel-mime-utils.c (header_content_type_is): Handle the case where ct != NULL, but type and subtype are, and also match that against text/plain. * camel-folder-summary.c: Bump summary file version. (message_info_save): Save the size from the messageinfo. (message_info_load): Load the size from the summary file. (message_info_load): Fixed up the time_t saving/loading. There was a reason the warning was left there ... obviously nobody could read the comment "/* warnings, leave them here */", why do i even bother. (camel_folder_summary_decode_time_t): Decode a time_t value from the summary file. (camel_folder_summary_encode_time_t): Encode a time_t value to the summary file. svn path=/trunk/; revision=5706
* Quote the mailbox name when sending a SELECT request otherwise mailboxesJeffrey Stedfast2000-10-044-60/+87
| | | | | | | | | | | | | | 2000-10-03 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-command.c (camel_imap_command): Quote the mailbox name when sending a SELECT request otherwise mailboxes with spaces in their names will cause problems. * camel-mime-message.c (camel_mime_message_set_reply_to): encode before setting. (camel_mime_message_set_from): Same. svn path=/trunk/; revision=5697
* New file containing camel_imap_command and friends. MajorDan Winship2000-10-049-1194/+735
| | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-command.c: New file containing camel_imap_command and friends. Major camel_imap_command rewrite to remove duplicated code, make the parsing of literals be more safe/correct, deal with RECENT/EXPUNGE responses more consistently, and make it possible to implement the AUTHENTICATE command. * providers/imap/camel-imap-utils.c (imap_parse_nstring): New function, to parse an IMAP "nstring". * providers/imap/camel-imap-store.c: Move command stuff to camel-imap-command.c. Update for camel_imap_command changes. * providers/imap/camel-imap-folder.c: Update for camel_imap_command changes. (imap_append_message): CRLF filter the message before sending it. * providers/imap/Makefile.am: Add camel-imap-command.[ch], remove camel-imap-stream.[ch] for now. svn path=/trunk/; revision=5693
* New convenience function to determine if there are any 8bit mime parts inJeffrey Stedfast2000-10-034-12/+221
| | | | | | | | | | | | | | | | | | | | | | 2000-10-02 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-message.c (camel_mime_message_has_8bit_parts): New convenience function to determine if there are any 8bit mime parts in a mime message. (camel_mime_message_encode_8bit_parts): New convenience function to recursively reencode all 8bit mime parts to either quoted-printable or base64 depending on which would be the best encoding for that part. * providers/smtp/camel-smtp-transport.c (smtp_data): If the mime message contains 8bit parts and the server doesn't support 8bit transfers, reencode those parts before proceding with the send. (smtp_mail): If the mime message contains 8bit parts and the server supports the 8BITMIME extension to SMTP, notify the server that we'll be sending it 8bit mime parts. (_send_to): Find out if the message contains 8bit parts. svn path=/trunk/; revision=5677
* Use the CamelInternetAddress parser. (smtp_get_email_addr_from_text):Jeffrey Stedfast2000-10-032-53/+22
| | | | | | | | | | 2000-10-02 Jeffrey Stedfast <fejj@helixcode.com> * providers/smtp/camel-smtp-transport.c (_send_to): Use the CamelInternetAddress parser. (smtp_get_email_addr_from_text): deprecated. svn path=/trunk/; revision=5672
* Remove default_ports.Dan Winship2000-10-0316-20/+24
| | | | | | | | | | | | | | * camel-provider.h: Remove default_ports. * camel-remote-store.c (remote_connect): Get default_port from CamelRemoteStore rather than CamelProvider. * providers/{imap,nntp,pop3}/camel-*-store.c: Initialize CamelRemoteStore::default_port * providers/*/camel-*-provider.c: Remove default_ports. svn path=/trunk/; revision=5669
* Remove camel_folder_{get,free}_subfolder_info, as we want to be able toDan Winship2000-10-0320-350/+511
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-folder.[ch]: Remove camel_folder_{get,free}_subfolder_info, as we want to be able to scan the whole subfolder tree without having to open any folders, so this needs to be in CamelStore. Remove can_hold_folders and can_hold_messages flags; things that don't hold messages are no longer considered CamelFolders. * camel-folder-summary.[ch]: Remove CamelFolderInfo stuff. * camel-store.[ch]: Add camel_store_{get,free}_folder_info, as well as camel_store_free_folder_info_full and ..._nop for default implementations, and camel_folder_info_free and camel_folder_info_build as convenience functions. Turn CamelFolderInfo into a tree structure and also add an "url" member. * providers/*/camel-*-folder.c: Remove subfolder_info and can_hold stuff. * providers/*/camel-*-store.c: Add folder_info stuff. * providers/imap/camel-imap-folder.c (imap_summary_free): Free the summary elements with camel_message_info_free, not camel_folder_info_free. Oops. * providers/imap/camel-imap-utils.c: const poison svn path=/trunk/; revision=5663
* More updating... still not usable, or even compilableDan Winship2000-10-034-46/+266
| | | | svn path=/trunk/; revision=5661
* another mem leak fixJeffrey Stedfast2000-09-291-0/+5
| | | | svn path=/trunk/; revision=5633
* Fixed some memory leaks. (camel_smtp_transport_init): InitializeJeffrey Stedfast2000-09-294-60/+61
| | | | | | | | | | | | | | | | | | | 2000-09-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/smtp/camel-smtp-transport.c: Fixed some memory leaks. (camel_smtp_transport_init): Initialize supports_8bit to FALSE. (smtp_helo): If server supports 8bit, set supports_8bit to TRUE. * camel-transport.h (struct _CamelTransport): Added variable gboolean supports_8bit (we'll need this eventually? - see bugzilla bug #53) * providers/smtp/camel-smtp-transport.c (smtp_get_email_addr_from_text): Ugh, no wonder people were getting illegal seek warnings *sigh*. I guess I can only blame myself for this one though :-( svn path=/trunk/; revision=5631
* Don't send the recipient data through smtp_get_email_addr_from_text - thisJeffrey Stedfast2000-09-293-18/+27
| | | | | | | | | | | | | 2000-09-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/smtp/camel-smtp-transport.c (_send_to): Don't send the recipient data through smtp_get_email_addr_from_text - this is a complete waste. In fact, we don't want to have to use that function ever. * camel-internet-address.c, camel-address.c: Added some gtk-doc comments. svn path=/trunk/; revision=5629
* Make sure to add the space char after an encoded word when the encoding isJeffrey Stedfast2000-09-292-0/+7
| | | | | | | | | 2000-09-28 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-utils.c (header_encode_string): Make sure to add the space char after an encoded word when the encoding is iso-8859-1. svn path=/trunk/; revision=5626
* When getting a literal string response, don't include the \r\n after theJeffrey Stedfast2000-09-294-1/+18
| | | | | | | | | | | | 2000-09-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message): When getting a literal string response, don't include the \r\n after the closing } (as in: "... {798}\r\n...") * providers/imap/camel-imap-stream.c (stream_read): Same. svn path=/trunk/; revision=5621
* New function to fold headers.Not Zed2000-09-2813-293/+4849
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-28 Not Zed <NotZed@HelixCode.com> * camel-mime-utils.c (header_fold): New function to fold headers. 2000-09-27 Not Zed <NotZed@HelixCode.com> * camel-mime-parser.c (folder_scan_header): If we had an empty header, then it must be end of the headers too. (folder_scan_init): No we dont need to init the outbuf with a nul terminator. * camel-folder-summary.c (camel_folder_summary_set_uid): New function to reset the uid to a higher value. * providers/mbox/camel-mbox-summary.c (camel_mbox_summary_sync): "something failed (yo!)" what sort of crap is this? Fixed all the indenting again, what wanker keeps running stuff through indent? (message_info_new): Check the uid we loaded off the disk, if it existed already, assign a new one. If it didn't then make sure the nextuid is higher. * camel-charset-map.c: New file, used to build a large unicode decoding mapping table, and use it to determine what is the lowest charset a given word can be encoded with. Uses tables from libunicode's source. * camel-internet-address.c (internet_encode): Use header_phrase_encode to properly encode the fullname, as required. refixed indenting. Who keeps doing that? (camel_internet_address_find_address): Changed fatal return/warnings into assertions. * camel-mime-utils.c (header_raw_append_parse): Check : explicitly (removed from is_fieldname() macro). (camel_mime_special_table): Changed to short, so we can represent more bit types. (quoted_encode): Take a mask of the safe chars for this encoding. (header_address_decode): Removed a #warning that makes no sense anymore. (header_decode_date): Fixed the 'broken date' parser code, if it ever decoded it it just threw away the result. (header_encode_string): Use better charset matching for encoding strings as well. 2000-08-31 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-summary.c (camel_mh_summary_sync): Save the index if we do a sync. (camel_mh_summary_check): Save the index here too. Probably. svn path=/trunk/; revision=5615
* Return untagged data in a GPtrArray rather than a string, since it savesDan Winship2000-09-285-142/+214
| | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-store.c (camel_imap_command_extended): Return untagged data in a GPtrArray rather than a string, since it saves processing time and is much easier to deal with for several commands. Update for camel_imap_folder_changed change. (camel_imap_fetch_command): Update for camel_imap_folder_changed change. (imap_connect, imap_folder_exists): Update for camel_imap_command_extended change. * providers/imap/camel-imap-folder.c (imap_get_message_count_internal, imap_get_subfolder_info_internal, imap_search_by_expression): Update for camel_imap_command_extended change. (imap_get_summary_internal, imap_get_message_info_internal): Use camel_imap_fetch_command here now to get around the camel_imap_command_extended change. (camel_imap_folder_changed): turn expunged into a GArray of ints rather than a GPtrArray of strings representing ints. svn path=/trunk/; revision=5608
* Quote the folder name as it may contain spaces.Jeffrey Stedfast2000-09-272-22/+37
| | | | | | | | | | | | | | | | | | | | 2000-09-26 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_count_internal): Quote the folder name as it may contain spaces. (imap_get_subfolder_info_internal): Same. * providers/imap/camel-imap-utils.c (imap_parse_list_response): Do proper unquoting for folder names. (func_get_current_date): Implemented. * providers/imap/camel-imap-store.c (imap_folder_exists): Quote the folder name as it may have spaces. (imap_create): Same. (check_current_folder): Same. svn path=/trunk/; revision=5592
* Again...wrap the folder names in quotesJeffrey Stedfast2000-09-233-8/+9
| | | | | | | | | | | | | | | | | | | | 2000-09-22 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_count_internal): Again...wrap the folder names in quotes * providers/imap/camel-imap-store.c (imap_folder_exists): Wrap the mailbox name in the LIST command in quotes just in case the folder has spaces in the name. (imap_create): Again, wrap folder name in quotes. (check_current_folder): Same... * providers/imap/camel-imap-utils.c (imap_parse_list_response): Update to unquote mailbox if it's quoted (allows us to get folders with spaces in the name). svn path=/trunk/; revision=5556
* The root folder's name is "", not the namespace. (camel_imap_folder_new):Dan Winship2000-09-234-11/+18
| | | | | | | | | | | | | * providers/imap/camel-imap-folder.c (imap_get_subfolder_info_internal): The root folder's name is "", not the namespace. (camel_imap_folder_new): constify folder_name. * providers/imap/camel-imap-store.c (get_folder): Create the folder with folder_name, not folder_path. (camel_imap_command_preliminary): Don't free cmdid here. svn path=/trunk/; revision=5552
* New function to convert Camel flags to an IMAP flag_list.Dan Winship2000-09-225-224/+161
| | | | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-utils.c (imap_create_flag_list): New function to convert Camel flags to an IMAP flag_list. (imap_parse_flag_list): Contrariwise. * providers/imap/camel-imap-store.c (camel_imap_command_*): Make the @ret arg actually optional, as (mostly) documented. (various): Don't pass "&result" to camel_imap_command_* if we're just going to immediately free it. Don't record status if we're not going to look at it. * providers/imap/camel-imap-folder.c: Likewise. (imap_summary_free): Use camel_folder_info_free. (imap_sync): Use imap_create_flag_list. Clear CAMEL_MESSAGE_FOLDER_FLAGGED after syncing so we don't keep re-syncing. (imap_append_message): Use imap_create_flag_list. Don't leak the memstream if the append fails. (imap_move_message_to): Use camel_folder_delete_message rather than doing it by hand. (imap_get_summary_internal, imap_get_message_info_internal): Use imap_parse_flag_list and header_raw_clear. (camel_imap_folder_changed): Use camel_message_info_free. svn path=/trunk/; revision=5544
* INBOX is case-insensitive. (get_root_folder_name): Make the root folder ""Dan Winship2000-09-224-263/+132
| | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-store.c (get_folder_name): INBOX is case-insensitive. (get_root_folder_name): Make the root folder "" rather than "/". (get_folder): Update for root folder name change. (camel_imap_store_get_toplevel_dir): Removed. (Unused, unneeded.) (camel_imap_store_folder_path): New function to turn a Camel folder name into the corresponding namespaced IMAP path. (imap_folder_exists): Make this take a store and a path rather than a folder. (imap_create): Likewise (get_folder): Update for camel_imap_store_folder_path and other changes. (check_current_folder): Likewise. * providers/imap/camel-imap-folder.c: Change a bunch of CamelStore variables to CamelImapStore (and add a few more) to prevent excess gratuitous casting. Use camel_imap_store_folder_path where appropriate. (camel_imap_folder_new): Update for root folder name change. svn path=/trunk/; revision=5541
* ack, remove the ~ and object filesJeffrey Stedfast2000-09-204-197/+0
| | | | svn path=/trunk/; revision=5511
* Use the linewrap filter to achieve full RFC0821 compliance.Jeffrey Stedfast2000-09-2010-129/+531
| | | | | | | | | | | 2000-09-19 Jeffrey Stedfast <fejj@helixcode.com> * providers/smtp/camel-smtp-transport.c (smtp_data): Use the linewrap filter to achieve full RFC0821 compliance. * camel-mime-filter-linewrap.[c,h]: New mime-filter to word-wrap. svn path=/trunk/; revision=5510
* When encoding the internet address, quote the name as the name may haveJeffrey Stedfast2000-09-202-31/+42
| | | | | | | | | | 2000-09-19 Jeffrey Stedfast <fejj@helixcode.com> * camel-internet-address.c (internet_encode): When encoding the internet address, quote the name as the name may have commas or any other token which may later confuse our address parser. svn path=/trunk/; revision=5506
* Fix the case where INBOX isn't returned in the folder listing.Dan Winship2000-09-202-1/+12
| | | | | | | | * providers/imap/camel-imap-folder.c (imap_get_subfolder_info_internal): Fix the case where INBOX isn't returned in the folder listing. svn path=/trunk/; revision=5505
* Removed (camel_folder_init, camel_folder_construct): New object initDan Winship2000-09-2021-646/+502
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-folder.c: (init): Removed (camel_folder_init, camel_folder_construct): New object init function and public object constructor to replace the old init method in a more Gtk-like fashion. (get_parent_folder, camel_folder_get_parent_folder): Removed. No CamelFolder subclass was ever setting the parent_folder member, no code has ever needed to look at it, and fixing it would actually be pretty hard. (get_subfolder_info, camel_folder_get_subfolder_info): Renamed from ..._names. Deals in CamelFolderInfo now. (free_subfolder_info, camel_folder_free_subfolder_info): Likewise. (get_subfolder, camel_folder_get_subfolder): Removed. CamelFolderInfo contains the subfolder's full name, so this is unnecessary now, and removing it lets us get rid of the CamelFolder separator member, which is needed for the default implementation of this function, but not otherwise needed for most providers. Also, lots of code style fixes. * providers/*: Update CamelFolder subclasses for changes, although none of them fill in the message counts in the CamelFolderInfo yet. svn path=/trunk/; revision=5503
* Added check for gnome-app-lib. Removed directories that have been moved toChristopher James Lahey2000-09-186-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * configure.in: Added check for gnome-app-lib. Removed directories that have been moved to gal. From addressbook/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * backend/ebook/Makefile.am, contact-editor/Makefile.am, ename/Makefile.am, gui/component/Makefile.am, gui/widgets/Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * backend/ebook/e-card.c, backend/pas/pas-backend-file.c, contact-editor/e-contact-editor-address.c, contact-editor/e-contact-editor-categories.c, contact-editor/e-contact-editor-categories.h, contact-editor/e-contact-editor-fullname.c, contact-editor/e-contact-editor.c, contact-editor/e-contact-save-as.c, ename/e-address-western.c, ename/test-ename-western-gtk.c, gui/component/addressbook-factory.c, gui/component/addressbook.c, gui/component/e-cardlist-model.h, gui/component/e-ldap-storage.c, gui/component/select-names/e-select-names-bonobo.c, gui/component/select-names/e-select-names-manager.c, gui/component/select-names/e-select-names-model.c, gui/component/select-names/e-select-names-table-model.c, gui/component/select-names/e-select-names-table-model.h, gui/component/select-names/e-select-names-text-model.h, gui/component/select-names/e-select-names.c, gui/component/select-names/e-select-names.h, gui/search/e-addressbook-search-dialog.c, gui/widgets/e-addressbook-model.h, gui/widgets/e-addressbook-view.c, gui/widgets/e-minicard-label.c, gui/widgets/e-minicard-view-widget.c, gui/widgets/e-minicard-view-widget.h, gui/widgets/e-minicard-view.c, gui/widgets/e-minicard-view.h, gui/widgets/e-minicard-widget.h, gui/widgets/e-minicard.c, gui/widgets/test-minicard-label.c, gui/widgets/test-reflow.c, printing/e-contact-print.c: Fixed the #include lines to deal properly with gal. From calendar/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * gui/Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * gui/calendar-model.h, gui/e-calendar-table.c, gui/e-day-view.c, gui/e-week-view-event-item.c, gui/e-week-view.c, gui/event-editor.c, gui/gncal-todo.c, gui/gnome-cal.c, gui/main.c, gui/print.c, gui/dialogs/task-editor.c: Fixed the #include lines to deal properly with gal. * gui/check-filled.xpm: New file since we can't include it from e-table anymore. From camel/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * camel-folder-search.c, camel-folder-search.h, camel-remote-store.c, providers/imap/camel-imap-folder.c, providers/imap/camel-imap-store.c: Fixed the #include lines to deal properly with gal. From composer/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * e-msg-composer-address-dialog.c, e-msg-composer-address-entry.c, e-msg-composer-attachment.c, e-msg-composer-hdrs.c, e-msg-composer.c: Fixed the #include lines to deal properly with gal. From e-util/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Removed all the files moved to gal. * e-dialog-widgets.c: Fixed the #include lines to deal properly with gal. * e-gui-utils.c, e-gui-utils.h: Removed all of the functionality that was moved to gal. * e-canvas-utils.c, e-canvas-utils.h, e-canvas-vbox.c, e-canvas-vbox.h, e-canvas.c, e-canvas.h, e-cursors.c, e-cursors.h, e-font.c, e-font.h, e-popup-menu.c, e-popup-menu.h, e-printable.c, e-printable.h, e-unicode.c, e-unicode.h, e-util.c, e-util.h, e-xml-utils.c, e-xml-utils.h: Moved to gal. From filter/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * filter-editor.c, filter-filter.c, filter-folder.c, filter-input.c, filter-message-search.c, filter-option.c, filter-rule.c, score-editor.c, vfolder-editor.c, vfolder-rule.c: Fixed the #include lines to deal properly with gal. From mail/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * component-factory.c, folder-browser-factory.c, folder-browser.c, mail-callbacks.c, mail-config-gui.c, mail-display.c, mail-display.h, main.c, message-list.c, message-list.h: Fixed the #include lines to deal properly with gal. From po/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * POTFILES.in: Removed files that have been moved to gal. From shell/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * e-component-registry.c, e-corba-storage-registry.c, e-corba-storage.c, e-folder-type-registry.c, e-folder.c, e-local-folder.c, e-local-storage.c, e-shell-folder-creation-dialog.c, e-shell-folder-selection-dialog.c, e-shell-folder-title-bar.c, e-shell-view.c, e-shell.c, e-shortcuts-view.c, e-shortcuts.c, e-storage-set-view.c, e-storage-set-view.h, e-storage-set.c, e-storage.c, evolution-local-storage.c, evolution-session.c, evolution-shell-client.c, evolution-shell-component-client.c, evolution-shell-component.c, evolution-shell-view.c, evolution-storage-listener.c, evolution-storage.c, main.c: Fixed the #include lines to deal properly with gal. From widgets/meeting-time-sel/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * e-meeting-time-sel-list-item.c, e-meeting-time-sel.c, e-meeting-time-sel.h: Fixed the #include lines to deal properly with gal. If you've read this far, you deserve a prize. The first email in my mailbox with the subject "What a commit message!" (and your physical mailing address somewhere in the message) will receive a free Helix Code T-shirt mailed to anywhere within the continental United States. I cannot be held responsible for problems with email systems anywhere. This is supposed to be for fun, so please don't make a fuss if something goes wrong and your mail doesn't reach me. Find my email elsewhere in this message, and if it's been more than a few days, you're probably too late. From widgets/misc/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * e-calendar-item.c, e-calendar.c, e-calendar.h, e-title-bar.c: Fixed the #include lines to deal properly with gal. * e-scroll-frame.c, e-scroll-frame.h: Moved to gal. From widgets/shortcut-bar/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added $(EXTRA_GNOME_CFLAGS) and $(EXTRA_GNOME_LIBS). Removed unneeded libraries. * e-icon-bar.c, e-icon-bar.h, e-shortcut-bar.c, e-shortcut-model.c, test-shortcut-bar.c: Fixed the #include lines to deal properly with gal. From widgets/ChangeLog: 2000-09-18 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Removed directories that have been moved to gal. * e-paned/.cvsignore, e-paned/Makefile.am, e-paned/e-hpaned.c, e-paned/e-hpaned.h, e-paned/e-paned.c, e-paned/e-paned.h, e-paned/e-vpaned.c, e-paned/e-vpaned.h: Moved to gal. * e-reflow/.cvsignore, e-reflow/Makefile.am, e-reflow/e-reflow-sorted.c, e-reflow/e-reflow-sorted.h, e-reflow/e-reflow.c, e-reflow/e-reflow.h: Moved to gal. * e-table/.cvsignore, e-table/ChangeLog, e-table/LICENSE, e-table/Makefile.am, e-table/ROADMAP.e-table, e-table/TODO, e-table/add-col.xpm, e-table/arrow-down.xpm, e-table/arrow-up.xpm, e-table/check-empty.xpm, e-table/check-filled.xpm, e-table/clip.png, e-table/e-cell-checkbox.c, e-table/e-cell-checkbox.h, e-table/e-cell-string.c, e-table/e-cell-text.c, e-table/e-cell-text.h, e-table/e-cell-toggle.c, e-table/e-cell-toggle.h, e-table/e-cell-tree.c, e-table/e-cell-tree.h, e-table/e-cell.c, e-table/e-cell.h, e-table/e-table-click-to-add.c, e-table/e-table-click-to-add.h, e-table/e-table-col-dnd.h, e-table/e-table-col.c, e-table/e-table-col.h, e-table/e-table-column-model.h, e-table/e-table-column.c, e-table/e-table-config.c, e-table/e-table-config.glade, e-table/e-table-config.glade.h, e-table/e-table-config.h, e-table/e-table-defines.h, e-table/e-table-example-1.c, e-table/e-table-example-2.c, e-table/e-table-field-chooser-dialog.c, e-table/e-table-field-chooser-dialog.h, e-table/e-table-field-chooser-item.c, e-table/e-table-field-chooser-item.h, e-table/e-table-field-chooser.c, e-table/e-table-field-chooser.glade, e-table/e-table-field-chooser.glade.h, e-table/e-table-field-chooser.h, e-table/e-table-group-container.c, e-table/e-table-group-container.h, e-table/e-table-group-leaf.c, e-table/e-table-group-leaf.h, e-table/e-table-group.c, e-table/e-table-group.glade, e-table/e-table-group.glade.h, e-table/e-table-group.h, e-table/e-table-header-item.c, e-table/e-table-header-item.h, e-table/e-table-header.c, e-table/e-table-header.h, e-table/e-table-item.c, e-table/e-table-item.h, e-table/e-table-model.c, e-table/e-table-model.h, e-table/e-table-one.c, e-table/e-table-one.h, e-table/e-table-scrolled.c, e-table/e-table-scrolled.h, e-table/e-table-selection-model.c, e-table/e-table-selection-model.h, e-table/e-table-simple.c, e-table/e-table-simple.h, e-table/e-table-size-test.c, e-table/e-table-sort-info.c, e-table/e-table-sort-info.h, e-table/e-table-sorted-variable.c, e-table/e-table-sorted-variable.h, e-table/e-table-sorted.c, e-table/e-table-sorted.h, e-table/e-table-sorter.c, e-table/e-table-sorter.h, e-table/e-table-subset-variable.c, e-table/e-table-subset-variable.h, e-table/e-table-subset.c, e-table/e-table-subset.h, e-table/e-table-text-model.c, e-table/e-table-text-model.h, e-table/e-table-tooltip.h, e-table/e-table-tree.h, e-table/e-table.c, e-table/e-table.h, e-table/e-tree-example-1.c, e-table/e-tree-example-2.c, e-table/e-tree-model.c, e-table/e-tree-model.h, e-table/e-tree-simple.c, e-table/e-tree-simple.h, e-table/image1.png, e-table/image2.png, e-table/image3.png, e-table/remove-col.xpm, e-table/sample.table, e-table/table-test.c, e-table/table-test.h, e-table/test-check.c, e-table/test-cols.c, e-table/test-table.c: Moved to gal. * e-text/.cvsignore, e-text/Makefile.am, e-text/e-entry-test.c, e-text/e-entry.c, e-text/e-entry.h, e-text/e-text-event-processor-emacs-like.c, e-text/e-text-event-processor-emacs-like.h, e-text/e-text-event-processor-types.h, e-text/e-text-event-processor.c, e-text/e-text-event-processor.h, e-text/e-text-model.c, e-text/e-text-model.h, e-text/e-text-test.c, e-text/e-text.c, e-text/e-text.h: Moved to gal. i.e., ... changed evolution to work with gal. svn path=/trunk/; revision=5490
* update CamelFolderInfo New function to free the contents of aDan Winship2000-09-183-7/+25
| | | | | | | | * camel-folder-summary.h: update CamelFolderInfo * camel-folder-summary.c (camel_folder_info_free): New function to free the contents of a CamelFolderInfo svn path=/trunk/; revision=5476
* Set camel_verbose_debug to TRUE if CAMEL_VERBOSE_DEBUG is set in theDan Winship2000-09-163-10/+29
| | | | | | | | | | * camel.c (camel_init): Set camel_verbose_debug to TRUE if CAMEL_VERBOSE_DEBUG is set in the environment. * camel-remote-store.c (remote_send_line, remote_recv_line): only log if camel_verbose_debug is TRUE. svn path=/trunk/; revision=5462
* Don't use dir_sep as top-level directory, use "/".Jeffrey Stedfast2000-09-153-8/+13
| | | | | | | | | | | | 2000-09-14 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (get_folder): Don't use dir_sep as top-level directory, use "/". * providers/imap/camel-imap-folder.c (imap_expunge): Get rid of unused variable. svn path=/trunk/; revision=5437
* Don't look at the response of the command. camel_imap_command_extended()Dan Winship2000-09-152-80/+9
| | | | | | | | | * providers/imap/camel-imap-folder.c (imap_expunge): Don't look at the response of the command. camel_imap_command_extended() processes EXPUNGE responses itself, so if we do it here too we remove twice as many summary items as we should. svn path=/trunk/; revision=5432
* Rewrote to take a third argument (gboolean *selectable) so that we canJeffrey Stedfast2000-09-143-21/+114
| | | | | | | | | | | | | | | | | | | | | | | 2000-09-13 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (imap_folder_exists): Rewrote to take a third argument (gboolean *selectable) so that we can find out if the folder is selectable or not as we look to see if it exists. Also, don't use EXAMINE because that will not work on non-selectable folders, so use LIST instead. (get_folder): Check to see if the folder exists even vefore calling imap_create as this will save time. If the folder does exist, find out if it's selectable. Moved the call to refresh_info here. * providers/imap/camel-imap-folder.c (imap_get_uids): Check for a NULL summary. (camel_imap_folder_new): Don't call refresh_info here - call it in get_folder() because we don't know if this folder even exists on the server yet! And even if it does, we don't know if it can hold messages or not yet. svn path=/trunk/; revision=5412
* Make sure *datalength is > 0 before calling camel_mime_filter_filterJeffrey Stedfast2000-09-132-15/+23
| | | | | | | | | | 2000-09-12 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-parser.c (folder_scan_step): Make sure *datalength is > 0 before calling camel_mime_filter_filter otherwise we will get a segfault if the filter calls iconv(). svn path=/trunk/; revision=5395
* fixes to make this beast distcheckPeter Teichman2000-09-131-0/+1
| | | | svn path=/trunk/; revision=5377
* Fixed a warning.Christopher James Lahey2000-09-093-0/+7
| | | | | | | | | 2000-09-08 Christopher James Lahey <clahey@helixcode.com> * providers/nntp/camel-nntp-auth.c, providers/nntp/camel-nntp-auth.h: Fixed a warning. svn path=/trunk/; revision=5265
* Make this not leak.Dan Winship2000-09-082-2/+8
| | | | | | | * camel-session.c (camel_session_get_storage_path): Make this not leak. svn path=/trunk/; revision=5243
* Make this take a path to a directory that Camel can use for its ownDan Winship2000-09-085-15/+196
| | | | | | | | | | | | | * camel-session.c (camel_session_new): Make this take a path to a directory that Camel can use for its own nefarious purposes. (camel_session_get_storage_path): New function to return a path that a service can use for its own nefarious sub-purposes. * camel-service.c (camel_service_get_path): New method (and useful default implementation) to get a (relative) pathname corresponding to the service. svn path=/trunk/; revision=5239
* *** empty log message ***Dan Winship2000-09-081-0/+7
| | | | svn path=/trunk/; revision=5233
* Make KPOP work again.Dan Winship2000-09-082-1/+7
| | | | | | | * providers/pop3/camel-pop3-store.c (connect_to_server): Make KPOP work again. svn path=/trunk/; revision=5232
* oops, spelling mistakeJeffrey Stedfast2000-09-071-2/+2
| | | | svn path=/trunk/; revision=5227
* Implemented (someone added these to camel-mime-message.h but neverJeffrey Stedfast2000-09-072-3/+28
| | | | | | | | | | | 2000-09-06 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-message.c (camel_mime_message_get_received_date): Implemented (someone added these to camel-mime-message.h but never implemented them!!) - though it may not be right. (camel_mime_message_get_sent_date): Same. svn path=/trunk/; revision=5226
* If a MIME part has no Content-Disposition, but does have a "name" on theDan Winship2000-09-062-4/+15
| | | | | | | | | * camel-mime-part.c (camel_mime_part_get_filename): If a MIME part has no Content-Disposition, but does have a "name" on the Content-Type, return that as the filename. (process_header): strstrip the Content-Description svn path=/trunk/; revision=5213
* care about response code. (get_HEAD_headers): same.Chris Toshok2000-09-0610-97/+304
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-05 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-utils.c (get_OVER_headers): care about response code. (get_HEAD_headers): same. (camel_nntp_get_headers): same. * providers/nntp/camel-nntp-store.h: get rid of CAMEL_NNTP_OK/ERR/FAIL. * providers/nntp/camel-nntp-store.c (camel_nntp_store_get_extensions): take CamelException arg and pass along to camel_nntp_command. (camel_nntp_store_get_overview_fmt): same. (nntp_store_connect): convert to using constants in camel-nntp-resp-codes.h (nntp_store_get_folder): make use of camel_nntp_folder_new. (camel_nntp_command_send_recv): new function to deal with auth challenge. (camel_nntp_command): split out most of this function into camel_nntp_command_send_recv. also, return the actual response code instead of CAMEL_NNTP_OK/ERR/FAIL. * providers/nntp/camel-nntp-resp-codes.h: new file. * providers/nntp/camel-nntp-folder.h: prototype for camel_nntp_folder_new. * providers/nntp/camel-nntp-folder.c (camel_nntp_folder_new): new convenience function. (nntp_folder_get_message): care more about the actual response code. * providers/nntp/Makefile.am (libcamelnntp_la_SOURCES): add camel-nntp-auth.c. (libcamelnntpinclude_HEADERS): add camel-nntp-auth.h. * providers/nntp/camel-nntp-auth.h: new file. * providers/nntp/camel-nntp-auth.c: new file. svn path=/trunk/; revision=5212
* Update for CamelObject and some other changesDan Winship2000-09-065-90/+69
| | | | svn path=/trunk/; revision=5210
* Cache provider, for caching a remote store locally. This is not done yet.Dan Winship2000-09-069-0/+1471
| | | | svn path=/trunk/; revision=5206
* Cleanup of lots of exception handling ; bugfixesPeter Williams2000-09-0611-262/+275
| | | | svn path=/trunk/; revision=5202
* A bit more e_utf8 wrappers here and thereLauris Kaplinski2000-09-022-1/+6
| | | | svn path=/trunk/; revision=5180
* Removed some unused functions.Christopher James Lahey2000-09-022-45/+5
| | | | | | | | | 2000-09-01 Christopher James Lahey <clahey@helixcode.com> * providers/imap/camel-imap-utils.c: Removed some unused functions. svn path=/trunk/; revision=5169
* remove get_folder_name. (nntp_store_get_folder_name): remove.Chris Toshok2000-09-012-8/+6
| | | | | | | | | | 2000-08-31 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (camel_nntp_store_class_init): remove get_folder_name. (nntp_store_get_folder_name): remove. svn path=/trunk/; revision=5158
* Email should now display correctly in GtkHTMLLauris Kaplinski2000-09-012-2/+10
| | | | svn path=/trunk/; revision=5154
* use camel_remote_store_recv_line.Chris Toshok2000-09-016-219/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-31 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-utils.c (get_OVER_headers): use camel_remote_store_recv_line. * providers/nntp/camel-nntp-folder.c (nntp_folder_get_message): use camel_remote_store_recv_line to build message. also, free our buffer so we don't leak like mad. * providers/nntp/camel-nntp-store.c: (camel_nntp_store_get_additional_data) remove. (camel_nntp_store_get_extensions): use camel_remote_store_recv_line. (camel_nntp_store_get_overview_fmt): same. also, don't rely on _get_additional_data anymore since it's easier to parse without. (camel_nntp_command): use camel_remote_store_send_string and camel_remote_store_recv_line. * providers/nntp/camel-nntp-store.h: CamelRemoteStore is the parent class now. remove istream/ostream since CamelRemoteStore takes care of that for us. also remove the prototype for camel_nntp_store_get_additional_data. * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_write): make sure to clear dirty bit. (camel_nntp_newsrc_read_for_server): don't worry about continually trying to open the file - if it fails we just return an unpopulated .newsrc file. svn path=/trunk/; revision=5153
* make this a bit more robust. try to create an empty .newsrc file for theChris Toshok2000-09-015-37/+294
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-31 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_read_for_server): make this a bit more robust. try to create an empty .newsrc file for the server if we can't open it for reading. also, don't allocate everything until we've opened the file. * providers/nntp/camel-nntp-utils.c (get_OVER_headers): make use of our overview field indices. (camel_nntp_get_headers): only call get_OVER_headers if the extension is present. warn if it's not - since get_HEAD_headers needs work before it works. * providers/nntp/camel-nntp-store.c (camel_nntp_store_get_extensions): new function - query the server for it's extensions. (camel_nntp_store_get_overview_fmt): new function - query the server for the overview format and build our table of the indices we care about. support the "full" suffix on fields. (nntp_store_connect): call camel_nntp_store_get_extensions and camel_nntp_store_get_overview_fmt. * providers/nntp/camel-nntp-store.h: add codes for extensions found on news.mozilla.org. only one that we care about is OVER. also, add CamelNNTPOverField and an enum of the overview fields that we care about. svn path=/trunk/; revision=5152
* Reimplemented. It should now work correctly for most possible VFolderJeffrey Stedfast2000-09-012-175/+333
| | | | | | | | | | 2000-08-31 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c (imap_translate_sexp): Reimplemented. It should now work correctly for most possible VFolder rules. svn path=/trunk/; revision=5151
* Don't save any exceptions caused by camel_imap_folder_changedJeffrey Stedfast2000-08-313-10/+51
| | | | | | | | | | | | | | | 2000-08-31 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_command_extended): Don't save any exceptions caused by camel_imap_folder_changed (camel_imap_fetch_command): Same. * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): Using a new way of calculating the first recent message that seems more accurate. Also added code to make sure we don't accidently add a duplicate summary. svn path=/trunk/; revision=5135
* (write_to_stream): Rearrange the logic so it always does charsetMichael Zucci2000-08-312-12/+22
| | | | | | conversion, and not just if we have a qp/base64 block. svn path=/trunk/; revision=5134
* (write_to_stream): Fix some warnings/use the right constructor,Michael Zucci2000-08-312-2/+5
| | | | | | oops. svn path=/trunk/; revision=5132
* Use the proper type checking function to check for text types.Not Zed2000-08-312-1/+19
| | | | | | | | | | | | 2000-08-31 Not Zed <NotZed@HelixCode.com> * camel-mime-part.c (write_to_stream): Use the proper type checking function to check for text types. (write_to_stream): If we have a charset on a text type that isn't us-ascii or utf-8, then we need to reencode it, so add a filter to do that too. svn path=/trunk/; revision=5131
* (append_latin1): Do an additional mask for account for c'sMichael Zucci2000-08-312-1/+3
| | | | | | undefined behaviour for sign extension whilst shifting right. svn path=/trunk/; revision=5129
* New function - even though its broken, we'll assume mailers send latin1Not Zed2000-08-312-2/+32
| | | | | | | | | | | | 2000-08-31 Not Zed <NotZed@HelixCode.com> * camel-mime-utils.c (append_latin1): New function - even though its broken, we'll assume mailers send latin1 headers instead of us-ascii. We just have to encode high chars into utf-8. (header_decode_text): Call append_latin1 for appending unencoded text segments. svn path=/trunk/; revision=5128
* Rewrote to ignore strings that look like server responses until it is sureJeffrey Stedfast2000-08-313-12/+69
| | | | | | | | | | 2000-08-30 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_fetch_command): Rewrote to ignore strings that look like server responses until it is sure that it has finished reading the literal string response. svn path=/trunk/; revision=5124
* Don't wrap printed strings in quotes, makes things messyJeffrey Stedfast2000-08-316-134/+452
| | | | | | | | | | | | | | | | | | | | | | 2000-08-30 Jeffrey Stedfast <fejj@helixcode.com> * camel-remote-store.c (remote_send_string): Don't wrap printed strings in quotes, makes things messy * providers/imap/camel-imap-folder.c (imap_get_message): Updated to use the camel_imap_fetch_command * providers/imap/camel-imap-stream.c (stream_read): Updated to use camel_imap_fetch_command * providers/imap/camel-imap-store.c (camel_imap_command_extended): No longer handles FETCH requests so no longer needs to be concerned with checking to make sure that server responses are valid (they have to be). (camel_imap_fetch_command): New convenience function that handles all FETCH requests svn path=/trunk/; revision=5122
* Make CamelServices connect only when told to (old behavior). Make ↵Peter Williams2000-08-317-59/+104
| | | | | | CamelRemoteStore do its stuff in service::connect, not ::post_connect. svn path=/trunk/; revision=5116
* General cleanup / moving stuff around to make things easier to follow.Jeffrey Stedfast2000-08-312-41/+61
| | | | | | | | | 2000-08-30 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c: General cleanup / moving stuff around to make things easier to follow. svn path=/trunk/; revision=5115
* Prevent exceptions from being overwrittenJeffrey Stedfast2000-08-305-193/+235
| | | | | | | | | | | | 2000-08-30 Jeffrey Stedfast <fejj@helixcode.com> * camel-remote-store.c: Prevent exceptions from being overwritten * providers/imap/camel-imap-folder.c (imap_expunge): Beautified (imap_get_subfolder_names_internal): Removed old code as the replacement code has now been tested and proven to work svn path=/trunk/; revision=5107
* Removed old code that will never be needed againJeffrey Stedfast2000-08-304-212/+102
| | | | | | | | | | | | | | 2000-08-29 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c: Removed old code that will never be needed again * providers/imap/camel-imap-store.c: Removed old code for try_connect - will never need this code (slurp_response): Update to make sure we aren't falsely detecting EXPUNGE flags svn path=/trunk/; revision=5106
* CamelRemoteStore: a new generic store for stores that connect to servers. ↵Peter Williams2000-08-3020-902/+1216
| | | | | | Prepare for the ability to cancel operations (much better exception handling). Clean up IMAP like nobody's business svn path=/trunk/; revision=5103
* Updated to check for EXPUNGE notificationsJeffrey Stedfast2000-08-305-21/+88
| | | | | | | | | | | | | | | | | | | | 2000-08-29 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_command_extended): Updated to check for EXPUNGE notifications * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): Updated to account for messages which have been expunged (now takes a new arg, a GPtrArray of message id's that have been expunged) (imap_expunge): Updated (we may want to just use the code in folder_changed now instead of doing our own summary expunging...but that can be fixed later) (imap_append_message): Updated. (imap_copy_message_to): Updated. (imap_move_message_to): Updated. svn path=/trunk/; revision=5098
* Fixed the hack around quoted string responses - should now handle themJeffrey Stedfast2000-08-293-165/+167
| | | | | | | | | | | | | 2000-08-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message): Fixed the hack around quoted string responses - should now handle them according to the specifications in the RFC * providers/imap/camel-imap-stream.c (stream_read): Updated to match the code currently used in camel-imap-folder.c svn path=/trunk/; revision=5092
* Free()ing memory allocated through alloca() is Not A Good Thing.Ettore Perazzoli2000-08-282-1/+5
| | | | svn path=/trunk/; revision=5078
* Use `g_free()' instead of `free()' in the `header_decode_text()'Ettore Perazzoli2000-08-272-1/+6
| | | | | | helper function. svn path=/trunk/; revision=5061
* Add support for specifying on which port to connect to a server; fix a ↵Peter Williams2000-08-2611-1/+25
| | | | | | potential infinite loop in unicode. svn path=/trunk/; revision=5041
* If the url path is "/" and the folder path is "/", just LIST "" "*" (thisJeffrey Stedfast2000-08-262-3/+4
| | | | | | | | | | | | 2000-08-25 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_subfolder_names_internal): If the url path is "/" and the folder path is "/", just LIST "" "*" (this should fix some cyrus imapd problems). Also, INBOX is case insensitive so use g_strcasecmp svn path=/trunk/; revision=5038
* If the url path is "/" and the folder path is "/", just LIST "" "*" (thisJeffrey Stedfast2000-08-262-7/+38
| | | | | | | | | | | 2000-08-25 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_subfolder_names_internal): If the url path is "/" and the folder path is "/", just LIST "" "*" (this should fix some cyrus imapd problems) svn path=/trunk/; revision=5036
* More UTF-8 handlingLauris Kaplinski2000-08-254-9/+17
| | | | svn path=/trunk/; revision=5032
* Remove this duplicate file to fix buildJP Rosevear2000-08-251-0/+2
| | | | | | | | 2000-08-24 JP Rosevear <jpr@helixcode.com> * src/libical/icalvcal.h: Remove this duplicate file to fix build svn path=/trunk/; revision=5030
* And here too.Not Zed2000-08-243-0/+13
| | | | | | | | | | | 2000-08-17 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-folder.c (mh_finalize): And here too. * providers/mbox/camel-mbox-folder.c (mbox_finalize): Close index on exit. svn path=/trunk/; revision=4996
* put commas between addresses.Dan Winship2000-08-242-0/+7
| | | | | | | * camel-mime-utils.c (header_address_list_format_append): put commas between addresses. svn path=/trunk/; revision=4985
* use BODY.PEEK, not BODY, so we don't set the message \Seen.Dan Winship2000-08-232-1/+7
| | | | | | | | * providers/imap/camel-imap-folder.c (imap_protocol_get_summary_specifier): use BODY.PEEK, not BODY, so we don't set the message \Seen. svn path=/trunk/; revision=4970
* Fixed a small warning.Christopher James Lahey2000-08-232-3/+7
| | | | | | | | 2000-08-22 Christopher James Lahey <clahey@helixcode.com> * providers/pop3/camel-pop3-store.c: Fixed a small warning. svn path=/trunk/; revision=4969
* ChangeLog updates.Peter Williams2000-08-231-0/+28
| | | | svn path=/trunk/; revision=4966
* Automatically connect services when given a valid URL (should hopefully ↵Peter Williams2000-08-238-95/+196
| | | | | | disconnect, too); remove the old movemail folder correctly. svn path=/trunk/; revision=4965
* Make sure newsrc is not null (nntp_folder_get_subfolder_names): dittoJP Rosevear2000-08-223-6/+31
| | | | | | | | | | | | | | | | | | 2000-08-21 JP Rosevear <jpr@helixcode.com> * providers/nntp/camel-nntp-folder.c (nntp_folder_get_subfolder_names): Make sure newsrc is not null (nntp_folder_get_subfolder_names): ditto * providers/nntp/camel-nntp-newsrc.c (camel_nntp_newsrc_get_subscribed_group_names): Programming check for newsrc == NULL (camel_nntp_newsrc_get_all_group_names): ditto (camel_nntp_newsrc_write_to_file): ditto (camel_nntp_newsrc_write): ditto svn path=/trunk/; revision=4908
* Make sure respbuffer is not null before manipulating it. If it is null,JP Rosevear2000-08-222-3/+17
| | | | | | | | | | | 2000-08-21 JP Rosevear <jpr@helixcode.com> * providers/nntp/camel-nntp-store.c (camel_nntp_command): Make sure respbuffer is not null before manipulating it. If it is null, return CAMEL_NNTP_FAIL and a decent error message. svn path=/trunk/; revision=4906
* Fix output for when the name is emptyPeter Williams2000-08-192-0/+7
| | | | svn path=/trunk/; revision=4873
* Whole buncha leak fixes thanks to PurifyMatthew Loper2000-08-173-3/+7
| | | | svn path=/trunk/; revision=4862
* More leak fixesPeter Williams2000-08-172-2/+7
| | | | svn path=/trunk/; revision=4857
* ChangeLog for previous camel-object commit.Peter Williams2000-08-171-0/+5
| | | | svn path=/trunk/; revision=4855
* Plug mem leaks.Peter Williams2000-08-171-0/+1
| | | | svn path=/trunk/; revision=4854
* Add support for copying messagesPeter Williams2000-08-162-1/+5
| | | | svn path=/trunk/; revision=4845
* Infrastructure for date-based queriesPeter Williams2000-08-153-2/+83
| | | | svn path=/trunk/; revision=4838
* Add camel-nntp-utils.hDan Winship2000-08-142-1/+5
| | | | | | | * providers/nntp/Makefile.am (libcamelnntpinclude_HEADERS): Add camel-nntp-utils.h svn path=/trunk/; revision=4811
* do a strcasecmp rather than just a strcmp when checking if a folder isDan Winship2000-08-142-1/+8
| | | | | | | | | * providers/imap/camel-imap-folder.c (imap_get_subfolder_names_internal): do a strcasecmp rather than just a strcmp when checking if a folder is "INBOX", since it is a case-insensitive name. svn path=/trunk/; revision=4801
* (imap_get_subfolder_names_internal): Add "INBOX" to the list asDan Winship2000-08-132-1/+3
| | | | | | g_malloc'ed memory, not a static string. svn path=/trunk/; revision=4792
* Don't assume the FETCH results will come back in the order they wereDan Winship2000-08-132-2/+8
| | | | | | | | * providers/imap/camel-imap-folder.c (imap_get_summary_internal): Don't assume the FETCH results will come back in the order they were requested. svn path=/trunk/; revision=4791
* Now takes a char * parameter rather than a streamJeffrey Stedfast2000-08-134-8/+126
| | | | | | | | | | | | | | | 2000-08-12 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_command_continuation): Now takes a char * parameter rather than a stream (camel_imap_command_continuation_with_stream): Same function as above but takes a stream parameter instead * providers/imap/camel-imap-folder.c (imap_append_message): Use camel_imap_command_continuation_with_stream svn path=/trunk/; revision=4786
* New function to do one round of attempted authentication. (pop3_connect):Dan Winship2000-08-132-105/+108
| | | | | | | | | * providers/pop3/camel-pop3-store.c (pop3_try_authenticate): New function to do one round of attempted authentication. (pop3_connect): Move a bunch of code out into pop3_try_authenticate and fix some bugs in the edge cases. svn path=/trunk/; revision=4785
* No longer calls try_connect() to get authtypesJeffrey Stedfast2000-08-132-2/+9
| | | | | | | | | 2000-08-12 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (query_auth_types): No longer calls try_connect() to get authtypes svn path=/trunk/; revision=4782
* Changed param order a bit and fixed some logicJeffrey Stedfast2000-08-124-28/+62
| | | | | | | | | | | | | 2000-08-11 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_command_continuation): Changed param order a bit and fixed some logic * providers/imap/camel-imap-folder.c (imap_append_message): Use the new multi-transactional convenience functions svn path=/trunk/; revision=4766
* New convenience function for multi-transactional commands (openingJeffrey Stedfast2000-08-124-33/+217
| | | | | | | | | | | | 2000-08-11 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_command_preliminary): New convenience function for multi-transactional commands (opening request) (camel_imap_command_continuation): New convenience function for multi-transactional commands (followup data) svn path=/trunk/; revision=4762
* Fixed a warning.Christopher James Lahey2000-08-122-2/+6
| | | | | | | | 2000-08-11 Christopher James Lahey <clahey@helixcode.com> * providers/mh/camel-mh-folder.c: Fixed a warning. svn path=/trunk/; revision=4759
* remove get_name and get_full_name assignments, since the camel-folder.cChris Toshok2000-08-122-16/+7
| | | | | | | | | | | 2000-08-11 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-folder.c (camel_nntp_folder_class_init): remove get_name and get_full_name assignments, since the camel-folder.c implementation does what we need. svn path=/trunk/; revision=4755
* use g_get_home_dir, since evolution_dir isn't available in the providers.Chris Toshok2000-08-122-3/+8
| | | | | | | | | | 2000-08-11 Chris Toshok <toshok@helixcode.com> * providers/nntp/camel-nntp-store.c (camel_nntp_store_get_toplevel_dir): use g_get_home_dir, since evolution_dir isn't available in the providers. svn path=/trunk/; revision=4754
* Fix the camel-folder's thaw handler. Implement event forwarding into the ↵Peter Williams2000-08-122-1/+6
| | | | | | main thread. svn path=/trunk/; revision=4744
* Implement. (mh_get_message_user_tag): Implement.Not Zed2000-08-115-4/+142
| | | | | | | | | | | | | | | | | 2000-08-11 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-folder.c (mh_set_message_user_tag): Implement. (mh_get_message_user_tag): Implement. * providers/mbox/camel-mbox-folder.c (mbox_get_message_user_tag): (mbox_set_message_user_tag): Implement. * camel-folder.c (camel_folder_set_message_user_tag): Routine to set message tags. (camel_folder_get_message_user_tag): And accessor. svn path=/trunk/; revision=4729
* Yay so lets fix an already fixed fix, again. (copy_message_to): and hereNot Zed2000-08-112-18/+19
| | | | | | | | | | 2000-08-11 Not Zed <NotZed@HelixCode.com> * camel-folder.c (move_message_to): Yay so lets fix an already fixed fix, again. (copy_message_to): and here too ... update for api change to append(). And removed another warning. svn path=/trunk/; revision=4728
* Fixed some warnings.Christopher James Lahey2000-08-1120-22/+70
| | | | | | | | | | | | | | | | 2000-08-10 Christopher James Lahey <clahey@helixcode.com> * camel-folder-search.c, camel-folder-summary.c, camel-medium.c, camel-mime-filter-charset.c, camel-mime-filter.c, camel-mime-filter.h, camel-mime-message.c, camel-mime-parser.c, camel-mime-part-utils.c, camel-mime-part.c, camel-mime-utils.c, camel-movemail.c, camel-multipart.c, camel-object.c, camel-stream-mem.c, providers/mbox/camel-mbox-folder.c, providers/mbox/camel-mbox-summary.c, providers/mh/camel-mh-folder.c, providers/smtp/camel-smtp-transport.c: Fixed some warnings. svn path=/trunk/; revision=4719
* t Zed <NotZed@HelixCode.com>Michael Zucci2000-08-112-28/+23
| | | | | | | | | | t Zed <NotZed@HelixCode.com> * providers/vee/camel-vee-folder.c (vee_folder_build_folder): Free the search properly. (vee_folder_build): And here too. svn path=/trunk/; revision=4718
* Removed unecessary change and fixed indenting.Michael Zucci2000-08-111-231/+214
| | | | svn path=/trunk/; revision=4716
* If we go over the max number of messages, don't keep requesting newJeffrey Stedfast2000-08-112-13/+23
| | | | | | | | | | 2000-08-10 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): If we go over the max number of messages, don't keep requesting new message summaries, just break. svn path=/trunk/; revision=4705
* Merge with camel-async.Peter Williams2000-08-11106-2641/+3455
| | | | svn path=/trunk/; revision=4687
* A better way to compress leading whitespace. The code is probably invalidNot Zed2000-08-1116-1041/+1170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-11 Not Zed <NotZed@HelixCode.com> * camel-mime-parser.c (folder_scan_header): A better way to compress leading whitespace. The code is probably invalid anyway, I dont think it will work across buffer boundaries. * providers/mbox/camel-mbox-folder.c (mbox_append_message): And write out proper format From lines here too. * providers/mbox/camel-mbox-summary.c (camel_mbox_summary_build_from): New function to build a more compatible mbox "From " line. (camel_mbox_summary_sync): Write From lines in the proper format. 2000-08-10 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-store.c (get_folder): Remove warnin g. * providers/mbox/camel-mbox-store.c (xrename): Kill some warnings with constification. * providers/imap/camel-imap-folder.c (imap_append_message): Fixed for append api change. Eek this routine seriously wastes memory. * providers/mh/camel-mh-folder.c (mh_search_free): Impelemnt. (mh_append_message): Fix for api change, and include user flags and tags in new message. * providers/vee/camel-vee-folder.c (vee_search_by_expression): Fix for search api change. * camel-folder.c (camel_folder_search_free): New function for freeing search results. (search_free): Changed my mind, implement a default that actually does something. Free as to the old interface. (camel_folder_append_message): Changed to accept a camelmessageinfo rather than flags, which just doesn't have enough info in it. (copy_message_to): Change for append_message api change. (move_message_to): Likewise. * providers/mbox/camel-mbox-folder.c (mbox_search_free): Implement. (mbox_append_message): Fix for api change, and also copy user flags/tags across to new summary. * camel-folder-search.c (search_user_tag): A search expression that returns the current use flag by name. (camel_folder_search_free_result): New function to free the result of a search. * camel-folder-summary.c: Bump summary version. (message_info_new): (message_info_load): (message_info_save): (camel_message_info_dup_to): (camel_message_info_free): Added support for arbitrary tag/value pairs (CamelTag's). (camel_tag_get): (camel_tag_set): (camel_tag_list_size): (camel_tag_list_free): Operations for working with CamelTags. svn path=/trunk/; revision=4683
* Fix the NNTP provider's Makefile.am so that it does not use installedEttore Perazzoli2000-08-093-5/+17
| | | | | | | Camel headers before the source ones. Also, get rid of an unused variable. svn path=/trunk/; revision=4631
* Reorder search result in summary order if we searched with a summary.Not Zed2000-08-092-3/+26
| | | | | | | | | | 2000-08-09 Not Zed <NotZed@HelixCode.com> * camel-folder-search.c (camel_folder_search_execute_expression): Reorder search result in summary order if we searched with a summary. svn path=/trunk/; revision=4618
* New code to keep an on-disk cache of what UIDs have been seen in a folder.Dan Winship2000-08-0911-42/+303
| | | | | | | | | | | | | | | | | | * camel-uid-cache.c: New code to keep an on-disk cache of what UIDs have been seen in a folder. * camel-provider.h: Add new flags CAMEL_PROVIDER_IS_SOURCE (mail can arrive in it by non-Camel means) and CAMEL_PROVIDER_IS_STORAGE (you can work with mail directly without needing to copy it local). * providers/*/camel-*-provider.c: Add flags as needed: imap and mbox are SOURCE and STORAGE. mh and nntp are just STORAGE, pop3 is just SOURCE. * camel-mime-message.c (process_header): Add another subject g_strstrip that fejj's earlier commit missed. svn path=/trunk/; revision=4616
* Add another subject g_strstrip that fejj's earlier commit missed.Dan Winship2000-08-092-1/+6
| | | | | | | * camel-mime-message.c (process_header): Add another subject g_strstrip that fejj's earlier commit missed. svn path=/trunk/; revision=4596
* Only retry another uid if we had a name clash, otherwise fail.Not Zed2000-08-089-12/+212
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-07 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-folder.c (mh_append_message): Only retry another uid if we had a name clash, otherwise fail. 2000-08-04 Not Zed <NotZed@HelixCode.com> * camel-url.c (camel_url_set_protocol): (camel_url_set_host): (camel_url_set_path): (camel_url_set_port): Url editing functions. 2000-08-02 Not Zed <NotZed@HelixCode.com> * providers/mh/camel-mh-summary.c (camel_mh_summary_sync): Expunge from the end, so the index isn't messed up when you remove a message. * providers/mh/camel-mh-folder.c (mh_append_message): Fix a bug where it would never open an output file/uid. * providers/mbox/camel-mbox-store.c (rename_folder): Implementation for mbox as well. * camel-store.c (camel_store_rename_folder): New method to rename folders. (rename_folder): Default implementation. * providers/mh/camel-mh-store.c (delete_folder): Implement this. (rename_folder): Implement a rename operation. svn path=/trunk/; revision=4590
* If we are trying to get a subfolder listing of the root folder, alwaysJeffrey Stedfast2000-08-083-10/+33
| | | | | | | | | | | | | | 2000-08-07 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_subfolder_names_internal): If we are trying to get a subfolder listing of the root folder, always make sure INBOX is there... * providers/imap/camel-imap-utils.c (imap_parse_list_response): Check for NIL as a directory separator. svn path=/trunk/; revision=4582
* Strip all \n's from the expressionJeffrey Stedfast2000-08-084-8/+36
| | | | | | | | | | | | 2000-08-07 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c (imap_translate_sexp): Strip all \n's from the expression * string-utils.c (strip): New convenience function to strip occurences of a single char from a string svn path=/trunk/; revision=4576
* Do a g_strstrip on the subject so we can stop getting those annoyingJeffrey Stedfast2000-08-082-1/+7
| | | | | | | | | | 2000-08-07 Jeffrey Stedfast <fejj@helixcode.com> * camel-mime-message.c (camel_mime_message_set_subject): Do a g_strstrip on the subject so we can stop getting those annoying leading spaces svn path=/trunk/; revision=4571
* Fix this to not require NULL-termination of the array.Dan Winship2000-08-072-2/+10
| | | | | | | * camel-folder.c (camel_folder_free_deep): Fix this to not require NULL-termination of the array. svn path=/trunk/; revision=4560
* If we fail to get a dir_sep, then supply the default of "/". (get_folder):Jeffrey Stedfast2000-08-052-28/+37
| | | | | | | | | | 2000-08-04 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (imap_connect): If we fail to get a dir_sep, then supply the default of "/". (get_folder): Undo changes by Peter svn path=/trunk/; revision=4537
* Coredump fix when IMAP get_folder with NULL dir_sepPeter Williams2000-08-052-1/+6
| | | | svn path=/trunk/; revision=4535
* Indexes into the flags array are message_number minus 1, not justDan Winship2000-08-052-2/+6
| | | | | | | | * providers/pop3/camel-pop3-folder.c (pop3_set_message_flags): (pop3_sync): Indexes into the flags array are message_number minus 1, not just message_number. svn path=/trunk/; revision=4533
* add a debugging macro for doing protocol tracing.Dan Winship2000-08-042-2/+29
| | | | | | | * providers/pop3/camel-pop3-store.c: add a debugging macro for doing protocol tracing. svn path=/trunk/; revision=4526
* Only call imap_get_summary_internal if the folder can hold messagesJeffrey Stedfast2000-08-043-7/+13
| | | | | | | | | | | | 2000-08-03 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (camel_imap_folder_new): Only call imap_get_summary_internal if the folder can hold messages * providers/nntp/camel-nntp-provider.c (camel_provider_module_init): Initialize the service_cache for the news/nntp providers svn path=/trunk/; revision=4519
* Initialize the service_cache for the news/nntp providersJeffrey Stedfast2000-08-042-6/+15
| | | | | | | | | 2000-08-03 Jeffrey Stedfast <fejj@helixcode.com> * providers/nntp/camel-nntp-provider.c (camel_provider_module_init): Initialize the service_cache for the news/nntp providers svn path=/trunk/; revision=4514
* srcdir != builddir fixPeter Williams2000-08-032-0/+6
| | | | svn path=/trunk/; revision=4506
* Kill this. It doesn't have any code to do anything the new mh providerDan Winship2000-08-0315-2068/+9
| | | | | | | | | | | * providers/MH: Kill this. It doesn't have any code to do anything the new mh provider doesn't do better. * providers/Makefile.am: Remove reference to MH subdir, and promote nntp to fully-supported status, since it does compile and all. svn path=/trunk/; revision=4496
* Trim trailing space from the subject. I've now seen replies from twoDan Winship2000-08-032-1/+10
| | | | | | | | | | | * camel-mime-message.c (camel_mime_message_set_subject): Trim trailing space from the subject. I've now seen replies from two different people that tricked the threading code by (a) not having References/In-Reply-To, and (b) adding an extra space to the end of the subject line so the subject-based threading fails too. Who writes these broken mailers anyway? svn path=/trunk/; revision=4495
* When forced to use the IP, place it in square brackets.Jeffrey Stedfast2000-08-022-7/+15
| | | | | | | | | 2000-08-01 Jeffrey Stedfast <fejj@helixcode.com> * providers/smtp/camel-smtp-transport.c (smtp_helo): When forced to use the IP, place it in square brackets. svn path=/trunk/; revision=4462
* New and improved sexp parser. An honest try at using e-sexp is wrapped inJeffrey Stedfast2000-08-023-224/+327
| | | | | | | | | | | | | | 2000-08-01 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c (imap_translate_sexp): New and improved sexp parser. An honest try at using e-sexp is wrapped in a #ifdef at the bottom of the file but is currently not used * providers/imap/camel-imap-folder.c (imap_search_by_expression): We want to do a UID SEARCH so we get UIDs back instead of sequence numbers svn path=/trunk/; revision=4461
* cvsignore filePeter Williams2000-08-011-0/+7
| | | | svn path=/trunk/; revision=4446
* Initial cut at mh provider. Well, it already does everythingNot Zed2000-08-0111-1/+1225
| | | | | | | | | | | | mbox does. 2000-08-01 Not Zed <NotZed@HelixCode.com> * providers/mh: New mh provider implementation. * providers/Makefile.am (SUBDIRS): Added mh provider. svn path=/trunk/; revision=4444
* Some IMAP servers don't wrap the UID in ()'s so don't depend on thatJeffrey Stedfast2000-08-013-208/+257
| | | | | | | | | | 2000-07-31 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_info_internal): Some IMAP servers don't wrap the UID in ()'s so don't depend on that (imap_get_summary_internal): Same svn path=/trunk/; revision=4443
* Oops, forgot to free node->function - not good.Jeffrey Stedfast2000-08-012-0/+6
| | | | | | | | | 2000-07-31 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c (free_sexp_node): Oops, forgot to free node->function - not good. svn path=/trunk/; revision=4438
* Buffer overrun fix in g_strfreev -- two more that I forgotPeter Williams2000-08-011-0/+2
| | | | svn path=/trunk/; revision=4432
* Buffer overrun fix in g_strfreevPeter Williams2000-08-012-0/+6
| | | | svn path=/trunk/; revision=4431
* New convenience function to translate a Camel sexp into the equivalentJeffrey Stedfast2000-08-015-46/+340
| | | | | | | | | | | | | | | | 2000-07-31 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-utils.c (imap_translate_sexp): New convenience function to translate a Camel sexp into the equivalent IMAP sexp. * providers/imap/camel-imap-store.c: More places now use imap_next_word * providers/imap/camel-imap-folder.c (imap_search_by_expression): Implemented initial version (this may or may not work quite right) svn path=/trunk/; revision=4428
* A few string overrun checks for the mime parserPeter Williams2000-08-012-6/+21
| | | | svn path=/trunk/; revision=4427
* Make sure the third word/token (whatever) is "EXPUNGE" and not somethingJeffrey Stedfast2000-07-292-24/+44
| | | | | | | | | | | | | 2000-07-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_expunge): Make sure the third word/token (whatever) is "EXPUNGE" and not something else like "EXISTS" or "RECENT". When removing the message from the summary also make sure to free that data to avoid leakage. Also make sure to subtract 1 from the 'id' since IMAP starts at 1 and our summary starts at 0 :-) svn path=/trunk/; revision=4411
* fixed a few logic errorsJeffrey Stedfast2000-07-292-8/+8
| | | | svn path=/trunk/; revision=4410
* Cleaned up a bit, now uses imap_next_word() (camel_imap_command_extended):Jeffrey Stedfast2000-07-293-35/+100
| | | | | | | | | | | | | | | | | | | 2000-07-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (camel_imap_status): Cleaned up a bit, now uses imap_next_word() (camel_imap_command_extended): Now uses imap_next_word(). When checking for RECENT, allow the first digit of the recent-count be between 0 and 9 inclusive instead of exclusive. * providers/imap/camel-imap-folder.c (imap_expunge): Optimized. No longer will it need to reload the summary as it now instead removes the appropriate message summaries from the cache. (camel_imap_folder_changed): If recent == 0 then return. If recent < 0 then just emit the folder_changed signal, don't reload summaries. svn path=/trunk/; revision=4409
* Get message count when STATUS is not available. (imap_init):Jeffrey Stedfast2000-07-294-55/+153
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-28 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_count_internal): Get message count when STATUS is not available. (imap_init): folder->has_search_capability is required for IMAP so should always be set to TRUE (is currently being set to FALSE as I've not yet implemented SEARCH support). (camel_imap_folder_changed): Seem to have fixed my optimization hack 2000-07-28 Jon K Hellan <hellan@acm.org> * providers/imap/camel-imap-store.h (CamelImapServerLevel): New enum. (CamelImapStore): Added server_level and has_status_capability members. * providers/imap/camel-imap-store.c (imap_connect): Detect IMAP4REV1, IMAP4 and STATUS in capability response. * providers/imap/camel-imap-folder.c (imap_get_message_count_internal): Use STATUS only if server supports it. TODO: Get message count when STATUS not supported. (imap_get_message, imap_get_summary_internal, imap_get_message_info_internal): Handle IMAP4 as well. (imap_protocol_get_summary_specifier): New function: Make a data item specifier for the header lines we need, appropriate to the server level. svn path=/trunk/; revision=4406
* Fixed my routine to only fetch new headers, my IDs were off by 1 on theJeffrey Stedfast2000-07-282-1/+9
| | | | | | | | | | | | 2000-07-27 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): Fixed my routine to only fetch new headers, my IDs were off by 1 on the high end, so when it would fetch the last newly arrived message it would fail and end up fetching all of the summaries because of the corruption. svn path=/trunk/; revision=4404
* If the path doesn't begin with a / and there is a host, prepend a / to theJeffrey Stedfast2000-07-282-2/+8
| | | | | | | | | 2000-07-27 Jeffrey Stedfast <fejj@helixcode.com> * camel-url.c (camel_url_to_string): If the path doesn't begin with a / and there is a host, prepend a / to the path. svn path=/trunk/; revision=4403
* Added camel-imap-utils.[c,h]Jeffrey Stedfast2000-07-286-108/+196
| | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-27 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/Makefile.am: Added camel-imap-utils.[c,h] * providers/imap/camel-imap-utils.[c,h]: Utilities for parsing server responses for use in both camel-imap-store.c and camel-imap-folder.c * providers/imap/camel-imap-folder.c (imap_get_summary_internal): Free all the pointers in the headers array. (imap_get_subfolder_names_internal): Updated to use imap_parse_list_response (imap_parse_subfolder_list): Removed in favor of imap_parse_list_response * providers/imap/camel-imap-store.c (camel_imap_command_extended): Free all the pointers in the data array. (imap_connect): Updated to use imap_parse_list_response and fixed a leak (folder_is_selectable): Updated. svn path=/trunk/; revision=4400
* Now uses a hash table for looking up message info rather than a linearJeffrey Stedfast2000-07-283-18/+41
| | | | | | | | | 2000-07-27 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_info): Now uses a hash table for looking up message info rather than a linear search :) svn path=/trunk/; revision=4398
* Fix Makefile.am booboo.Peter Williams2000-07-2810-18/+5
| | | | svn path=/trunk/; revision=4394
* Make the mime parser a bit less reckless. More reckful?Matthew Loper2000-07-273-3/+13
| | | | svn path=/trunk/; revision=4365
* routine to call an external movemail program. (camel_movemail): NukeDan Winship2000-07-273-48/+141
| | | | | | | | | | * camel-movemail.c (movemail_external): routine to call an external movemail program. (camel_movemail): Nuke return value, use movemail_external when available and useful, and don't delete "dest" on errors, since it might have started non-empty. svn path=/trunk/; revision=4355
* Should now always prepend a '/' before the path if it doesn't alreadyJeffrey Stedfast2000-07-262-14/+19
| | | | | | | | | | | 2000-07-26 Jeffrey Stedfast <fejj@helixcode.com> * camel-url.c (camel_url_to_string): Should now always prepend a '/' before the path if it doesn't already exist. * providers/imap/camel-imap-folder.c: Fixed a few compiler warnings svn path=/trunk/; revision=4346
* Fixed a few compiler warningsJeffrey Stedfast2000-07-262-2/+6
| | | | | | | | 2000-07-26 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c: Fixed a few compiler warnings svn path=/trunk/; revision=4345
* Fixed the real problem that Peter was running into.Jeffrey Stedfast2000-07-262-21/+29
| | | | | | | | | 2000-07-25 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_summary_free): Fixed the real problem that Peter was running into. svn path=/trunk/; revision=4321
* Don't add a Mime-Version header to a message that already has one.Dan Winship2000-07-263-5/+14
| | | | | | | | | | * camel-mime-message.c (write_to_stream): Don't add a Mime-Version header to a message that already has one. * camel-internet-address.c (internet_encode): Don't put <>s around addresses with no name part. svn path=/trunk/; revision=4318
* IMAP expunge crash prevention... still not right...Peter Williams2000-07-262-0/+8
| | | | svn path=/trunk/; revision=4316
* Optimized to try and get the new message headers without reloading theJeffrey Stedfast2000-07-254-87/+81
| | | | | | | | | | | | 2000-07-25 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (camel_imap_folder_changed): Optimized to try and get the new message headers without reloading the entire summary from scratch. (imap_get_summary_internal): Will now sync() before attempting to reload the summary so that flags are set in the reloaded summary as well. svn path=/trunk/; revision=4309
* Updated to give special attention to the root folder.Jeffrey Stedfast2000-07-254-24/+50
| | | | | | | | | | | | | | | 2000-07-24 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-store.c (get_folder): Updated to give special attention to the root folder. * providers/imap/camel-imap-folder.c (imap_get_subfolder_names_internal): Updated to handle the root folder (imap_get_message_count_internal): return 0 if folder can't hold messages (camel_imap_folder_new): Change so that root folder gets special attention and always gets can_hold_messages set to FALSE svn path=/trunk/; revision=4308
* Remove exceptions from a number of methods that work on what ought to beDan Winship2000-07-259-471/+318
| | | | | | | | | | | | | | | * camel-folder.c: Remove exceptions from a number of methods that work on what ought to be static data: get_parent_folder, get_parent_store, get_message_count, get_unread_message_count, get_permanent_flags, get_message_flags, set_message_flags, get_message_user_flag, set_message_user_flag, get_uids, get_summary, get_subfolder_names. Turn camel_folder_delete_message into a macro. (Mostly a pull-up from the camel-async branch.) * providers/{imap,mbox,nntp,pop3,vee}: Update for CamelFolder changes svn path=/trunk/; revision=4303
* Updated to port easily to the new Camel API (imap_init): Don't SELECTJeffrey Stedfast2000-07-252-36/+34
| | | | | | | | | | 2000-07-24 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_get_message_info): Updated to port easily to the new Camel API (imap_init): Don't SELECT INBOX, we don't need to do that svn path=/trunk/; revision=4302
* Initialize the summary and subfolder listing. (imap_summary_free): NowJeffrey Stedfast2000-07-255-103/+194
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-24 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (camel_imap_folder_new): Initialize the summary and subfolder listing. (imap_summary_free): Now takes a GPtrArray arg rather than a CamelImapFolder as it increases it's usefullness for free()'ing temporary summaries. (imap_get_message_count_internal): A new convenience function for getting the actual message count on a server to be used by imap_get_summary_internal) (imap_get_message_count): Since the Camel API is on the move again, the future version of this function will not be able to make a call to the store, it must only access previously fetched data (thus the creation of the _internal function) (imap_get_subfolder_names_internal): Again, because the future version of imap_get_subfolder_names will not take an exception, we must rename this function which will be called by camel_imap_folder_new() (imap_get_subfolder_names): We now return the previously collected subfolder listing that the _internal function fetched previously (imap_get_summary_internal): Again, same idea as the previous _internal functions... (imap_get_summary): Again... now returns a previously aquired summary * providers/imap/camel-imap-store.c (imap_noop): This will hopefully prevent the imap store from disconnecting. (imap_connect): Modified to add a gtk timeout event that will call imap_noop() every 10 minutes (we may want to change this time value) (imap_disconnect): Modified to remove the NOOP timeout event from the store. (camel_imap_command_extended): Commented out the code that would try and detect if the store was disconnected and then reconnect if it was needed. svn path=/trunk/; revision=4298
* Remove camel_folder_get_message_uid, which was not used, and notDan Winship2000-07-244-54/+6
| | | | | | | | | | * camel-folder.[ch]: Remove camel_folder_get_message_uid, which was not used, and not implemented by any provider. * providers/nntp/camel-nntp-folder.c: Remove get_message_uid non-implementation. svn path=/trunk/; revision=4292