Commit Graph

157 Commits

Author SHA1 Message Date
338344b2e4 Set the preface/postface from the parser into the multipart object.
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
2000-11-04 02:34:46 +00:00
f351369e51 Merged in camel-incremental-branch.
2000-11-02  Not Zed  <NotZed@HelixCode.com>

        * Merged in camel-incremental-branch.

svn path=/trunk/; revision=6336
2000-11-02 03:35:04 +00:00
abe39be172 Take an additional argument, "break_lines", saying whether or not to add
* 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
2000-10-30 16:58:53 +00:00
201718d553 Remove previous comment about Outlook brokenness, since it turns out the
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
2000-10-27 22:05:45 +00:00
aa1f585298 Work around Outlook brokenness in iMIP parsing by only quoting
* 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
2000-10-27 20:19:48 +00:00
e81e64f8dd Simple subclass of CamelFolderSummary that also keeps a UIDVALIDITY value
* 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
2000-10-12 20:55:11 +00:00
6c337e9ea0 Removed temp_message_buffer, and content_input_stream fields which seem to
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
2000-10-12 13:38:51 +00:00
8a246228a9 teach camel about "its" vs. "it's"
2000-10-10  Jacob "Ulysses" Berkman  <jacob@helixcode.com>

	* camel-*.c: teach camel about "its" vs. "it's"

svn path=/trunk/; revision=5819
2000-10-10 16:57:29 +00:00
ff1f5fc3dd Fix so that we don't encode every single char in the word. Also, do we
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
2000-10-06 19:05:22 +00:00
734f0a9402 Fix so that we don't encode every single char in the word. Also, do we
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
2000-10-06 17:59:39 +00:00
1d7f431754 Encode the name part of the address and don't quote the name.
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
2000-10-06 00:59:34 +00:00
19d6689653 Modified to not encode space chars in the middle of a line. (isblank): New
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
2000-10-05 21:26:28 +00:00
47a2f8444f Handle the case where ct != NULL, but type and subtype are, and also match
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
2000-10-04 15:56:32 +00:00
7ba4d2bed2 Make sure to add the space char after an encoded word when the encoding is
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
2000-09-28 23:57:54 +00:00
e71de4c021 New function to fold headers.
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
2000-09-28 11:31:29 +00:00
26f1d04d35 (append_latin1): Do an additional mask for account for c's
undefined behaviour for sign extension whilst shifting right.

svn path=/trunk/; revision=5129
2000-08-31 01:49:21 +00:00
dbe98bddd3 New function - even though its broken, we'll assume mailers send latin1
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
2000-08-31 01:46:44 +00:00
a1bf7aa6c4 Use g_free()' instead of free()' in the `header_decode_text()'
helper function.

svn path=/trunk/; revision=5061
2000-08-27 00:59:45 +00:00
81f994a359 More UTF-8 handling
svn path=/trunk/; revision=5032
2000-08-25 04:31:13 +00:00
0131da3b09 put commas between addresses.
* camel-mime-utils.c (header_address_list_format_append): put
	commas between addresses.

svn path=/trunk/; revision=4985
2000-08-23 19:58:51 +00:00
40eea3692e Fixed some warnings.
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
2000-08-11 02:57:11 +00:00
f67eb8f791 A few string overrun checks for the mime parser
svn path=/trunk/; revision=4427
2000-07-31 19:57:49 +00:00
ed21f552bb Make the mime parser a bit less reckless. More reckful?
svn path=/trunk/; revision=4365
2000-07-26 21:02:08 +00:00
57d6e1cd92 Remove some text cruft i was using for testing.
svn path=/trunk/; revision=4136
2000-07-13 04:03:38 +00:00
0fcc4e0a67 Reset filter on setup. (reset): When resetting qp encoding, set the state
2000-07-13  Not Zed  <NotZed@HelixCode.com>

        * camel-mime-filter-basic.c (camel_mime_filter_basic_new_type):
        Reset filter on setup.
        (reset): When resetting qp encoding, set the state to -1, instead
        of 0.

        * camel-mime-utils.c (quoted_encode_step): Actually count the
        characters output sofar (it never counted any).  Bunch of other
        fixes.
        (quoted_encode_close): Also flush out final character, if ther's
        one.

svn path=/trunk/; revision=4135
2000-07-13 04:02:13 +00:00
90d51074c9 New function to copy a header_references structure.
* camel-mime-utils.c (header_references_dup): New function to copy
	a header_references structure.

	* camel-folder-summary.c (camel_message_info_dup_to): New function
	to (deep) copy the data from one CamelMessageInfo into another.
	(camel_message_info_free): And free the data.

	* providers/vee/camel-vee-folder.c (vee_sync): Implement. (empty).
	(vee_search_by_expression): belatedly update for
	camel_folder_search change.
	(vee_folder_build): belatedly update for camel_folder_search
	change. Use camel_message_info_dup_to and camel_message_info_free
	(in particular, so that we get message_id and references info so
	vfolders can be threaded).
	(vee_folder_build_folder): Ditto.

svn path=/trunk/; revision=4024
2000-07-09 22:40:49 +00:00
b817b9cb3e Work around In-Reply-To's with unquoted punctuation. So many broken
* camel-mime-utils.c (header_references_decode): Work around
	In-Reply-To's with unquoted punctuation. So many broken mailers.

svn path=/trunk/; revision=3962
2000-07-07 21:46:03 +00:00
5eae81928c Make this deal with the full RFC822 References/In-Reply-To format rather
* camel-mime-utils.c (header_references_decode): Make this deal
	with the full RFC822 References/In-Reply-To format rather than
	just the more-nicely-behaved RFC1036 version. (Needed to parse
	In-Reply-To headers with extra junk in them.)

svn path=/trunk/; revision=3926
2000-07-06 21:28:23 +00:00
5348f464f5 Added prototype for uudecode_step
2000-07-05  Jeffrey Stedfast  <fejj@helixcode.com>

	* camel-mime-utils.h: Added prototype for uudecode_step

	* camel-mime-utils.c (uudecode_step): Cleaned up some junk that
	should have been cleaned up when debugging printf's were taken out.

svn path=/trunk/; revision=3899
2000-07-05 21:24:53 +00:00
4c0c741c6d A rather complex uudecoder written in the spirit of Zucchi-ness, is it up
2000-07-02  Jeffrey Stedfast  <fejj@helixcode.com>

	* camel-mime-utils.c (uudecode_step): A rather complex uudecoder
	written in the spirit of Zucchi-ness, is it up to par? Only the
	Z-man can tell us :-)

svn path=/trunk/; revision=3856
2000-07-02 05:17:40 +00:00
c07840479d Utilities for parsing broken date strings.
2000-06-30  Jeffrey Stedfast  <fejj@helixcode.com>

	* broken-date-parser.[c,h]: Utilities for parsing broken
	date strings.

	* providers/imap/camel-imap-folder.c: fixed some mem leaks

svn path=/trunk/; revision=3840
2000-07-01 00:11:01 +00:00
6ae3f35ec3 oops, forgot I had blocked that code from running :)
svn path=/trunk/; revision=3837
2000-06-30 22:48:21 +00:00
68670a0f42 Wrote some code to try and un-mangle broken date formats and then parse
2000-06-30  Jeffrey Stedfast  <fejj@helixcode.com>

	* camel-mime-utils.c (header_decode_date): Wrote some code to try
	and un-mangle broken date formats and then parse that new string
	instead.

svn path=/trunk/; revision=3836
2000-06-30 22:43:42 +00:00
f0600c2ccb KLUDGE! Since neither ETable nor GtkHTML supports UTF-8 yet, output
* camel-mime-utils.c (rfc2047_decode_word):
	* camel-mime-part-utils.c (simple_data_wrapper_construct_from_parser):
	* camel-folder-summary.c (summary_build_content_info):
	KLUDGE! Since neither ETable nor GtkHTML supports UTF-8 yet,
	output ISO-8859-1 instead, so Ettore can read his Italian mail. :)
	This will be reverted later.

svn path=/trunk/; revision=3597
2000-06-16 22:42:12 +00:00
9da3c9d231 Properly dereference warning/debug messages. (header_references_decode):
2000-06-07  Not Zed  <NotZed@HelixCode.com>

        * camel-mime-utils.c (header_msgid_decode_internal): Properly
        dereference warning/debug messages.
        (header_references_decode): Check we actually have msgid stuff
        before trying to decode it ...

svn path=/trunk/; revision=3467
2000-06-07 21:40:52 +00:00
3164235947 Ick, damn signs! Fix a bug with sign extended bytes.
2000-06-02  Not Zed  <NotZed@HelixCode.com>

        * camel-mime-utils.c (base64_encode_step): Ick, damn signs!  Fix a
        bug with sign extended bytes.

        * camel-mime-filter-smtp.c (filter): Changed layout/logic slightly
        (to match From filter)

svn path=/trunk/; revision=3408
2000-06-02 22:57:31 +00:00
4cf5bbfa5a If we get a funny result, just throw it out. Basically a fix for the one
2000-06-02  Not Zed  <NotZed@HelixCode.com>

        * camel-mime-utils.c (header_decode_date): If we get a funny
        result, just throw it out.  Basically a fix for the one true
        broken TradeClient.

2000-06-01  Not Zed  <NotZed@HelixCode.com>

        * camel-folder-summary.c (message_info_free): Free
        references/messsage id.
        (message_info_save): Save them.
        (message_info_load): Load them.
        (message_info_new): And get them from the new message.
        (CAMEL_FOLDER_SUMMARY_VERSION): Bumped for new changes.

        * camel-folder-summary.h: Added references and messageid to
        summary.

svn path=/trunk/; revision=3391
2000-06-02 18:09:18 +00:00
2e7d848819 Use foo@bar' rather than "" <foo@bar>' for email addresses with no name
* camel-mime-utils.c (header_address_list_format_append): Use
	`foo@bar' rather than `"" <foo@bar>' for email addresses with no
	name component.

svn path=/trunk/; revision=3248
2000-05-28 17:36:54 +00:00
e17b3c90f4 Big bunch o memleaks fixed.
2000-05-11  NotZed  <NotZed@HelixCode.com>

        * camel-mime-part.c (write_to_stream): Unref the filter after
        adding it to the filtering stream.

        * providers/mbox/camel-mbox-summary.c
        (camel_mbox_summary_finalise): Free the folder path.

        * camel-folder-summary.c (camel_folder_summary_finalise): Free the
        summary path.

        * camel-internet-address.c (internet_decode): Free multiple entry
        addresses properly.

        * camel-mime-utils.c (header_decode_mailbox): Plugged another
        memleak, free text after converting it.
        (header_decode_addrspec): More leaks plugged.

        * camel-mime-message.c (finalize): Free message_uid.
        (finalize): Free the recipients hashtable.

svn path=/trunk/; revision=2989
2000-05-11 18:39:53 +00:00
b7f49ccf57 Merged NEW_SUMMARY branch back to trunk, and resolved conflicts.
2000-05-08  NotZed  <NotZed@HelixCode.com>

	* Merged NEW_SUMMARY branch back to trunk, and resolved conflicts.

	* providers/mbox/camel-mbox-summary.c (camel_mbox_summary_update):
	Return status.

	* camel-stream-filter.c (do_close): We NEED a stream close.

svn path=/trunk/; revision=2906
2000-05-08 05:24:54 +00:00
aa7851f1f0 And same here ...
2000-05-05  NotZed  <NotZed@HelixCode.com>

        * camel-folder-summary.c: And same here ...

        * camel-mime-utils.c: Defined out some memory profiling stuff I
        left there by mistake.

        * camel-mime-parser.c (folder_scan_content): Apply the fix from
        the header scanner to here too.
        (folder_scan_header): Only check for end of header if we have
        space for it (didn't end the read with a newline)
        (folder_scan_header): inptr is the only real thing we need
        registerised for performance.  Try to help the compiler be smart
        about it ..
        (folder_scan_header): Simplified the save header case a tad.

        Commented out some memory profiling stuff.

svn path=/trunk/; revision=2811
2000-05-05 08:47:02 +00:00
5
022c7ab1f2 Plug a memory leak. (header_decode_text): Fixed memory leaks with
2000-05-05    <notzed@helixcode.com>

        * camel-mime-utils.c (header_decode_mailbox): Plug a memory leak.
        (header_decode_text): Fixed memory leaks with g_string_append().
        (header_encode_string): And here too, and a few other places.  The
        glib api is so awful ...
        (header_content_type_decode): More memory leaks, more left ...

2000-05-05    <notzed@helixcode.com>

        * camel-mime-parser.c (folder_scan_init_with_fd): Make sure we
        init the end of buffer sentinal!
        (folder_scan_init_with_stream): And here too ...

svn path=/trunk/; revision=2810
2000-05-05 07:28:20 +00:00
214c910550 Maxcount is minimum of the max and the requested count, not the maximum :)
2000-05-04  NotZed  <NotZed@HelixCode.com>

        * providers/mbox/camel-mbox-folder.c (summary_get_message_info):
        Maxcount is minimum of the max and the requested count, not the
        maximum :)

        * camel-mime-parser.c (folder_scan_content): Properly set midline,
        so we dont falsely catch offset boundary markers (i.e. From inside
        content).
        (folder_read): Set a sentinal on the end of the read data (\n) so
        we dont have to check the buffer boundary in the inner loop.
        (mempool_*): New experimental memory management routines, speed
        up simple structure parsing by about 25% ... not compiled in by
        default.  Something similar may be needed for camel-mime-utils to
        address performance issues with g_malloc and friends.

        * camel-mime-utils.c: Added a macro w(x) used to wrap all warnings
        about mime/rfc violations, so they can be turned off.

        * camel-folder-summary.c (summary_build_content_info): Step after
        the end of a message ...
        Turn into a stand-alone program for testing and profiling.

svn path=/trunk/; revision=2808
2000-05-05 03:46:07 +00:00
f8bfbef0a7 No, we're not going to have g_strcasecmp for no good reason,
not even if its slipped in with no changelog.

2000-05-04  NotZed  <NotZed@HelixCode.com>

	* providers/mbox/camel-mbox-summary.c: Yes, and anotherone.

	* camel-mime-utils.c: And another one.

	* camel-mime-part.c: And another one.

	* camel-mime-part-utils.c: And another one.

	* camel-folder-search.c: And another one.

	* camel-mime-parser.c: Reverted a change wihtout a ChangeLog entry.

2000-05-04  NotZed  <NotZed@HelixCode.com>

	* camel-folder-summary.[hc]: Yes, CamelFolderSummary is back ...
	... re-usable class to summarise and index any stream or message
	and to manage/load/save the created summaries.

	* camel-folder.c: Include string.h to kill a warning.

2000-05-03  NotZed  <NotZed@HelixCode.com>

	* camel-folder.h: Added pos/bodypos/endpos to the basic message
	content info object.  Size to be removed?  Moved the
	messageconentinfo and messageinfo back to camel-folder-summary.h.

	* camel-mime-filter-index.c (camel_mime_filter_index_set_ibex):
	New function to (re)set the index to use on a filter.

	* camel-mime-parser.c (camel_mime_parser_scan_from): Whole bunch
	of inline docs.
	(camel_mime_parser_drop_step): New function to drop a state from
	the parser.  Needs more testing.

svn path=/trunk/; revision=2789
2000-05-04 05:45:30 +00:00
3ccfb61399 s/strcasecmp/g_strcasecamp/ everywhere except intl/, per michael's
request.

svn path=/trunk/; revision=2776
2000-05-03 14:43:10 +00:00
ff8bc3108a If the iconv handle is -1, then dont try and convert (crashes
2000-05-03  NotZed  <NotZed@HelixCode.com>

        * camel-mime-utils.c (rfc2047_decode_word): If the iconv handle is
        -1, then dont try and convert (crashes unicode_iconv?).
        (rfc2047_decode_word): Use alloca for variables instead of
        g_malloc - by the rfc they should always be short.
        (rfc2047_decode_word): If we can't do the charset conversion, undo
        the quoted-printable/base64 at least?  Should probably convert
        unknown characters to the utf-8 unknown character.

svn path=/trunk/; revision=2774
2000-05-03 04:20:26 +00:00
f27621c3a2 fix typo when dereferencing saveoffset.
2000-05-02  Larry Ewing  <lewing@helixcode.com>

	* camel-mime-utils.c (header_decode_date): fix typo when
	dereferencing saveoffset.

svn path=/trunk/; revision=2771
2000-05-03 03:35:31 +00:00
19e9448267 Dont try and check a NULL header.
2000-04-27  NotZed  <NotZed@HelixCode.com>

        * camel-mime-utils.c (check_header): Dont try and check a NULL
        header.

        * camel-recipient.[ch]: Dead.  Its not pining.

        * camel-mime-message.h: Dont include recipients.h anymore.

        * camel-mime-message.c (camel_mime_message_add_recipient): Accept
        name/address separately, and store in an CamelInternetAddress.
        (add_recipient): Removed.
        (remove_recipient): Removed.
        (remove_recipient_address): Renamed from remove_receipient, works
        via address.
        (camel_mime_message_remove_recipient_name): New function to remove
        by name.
        (get_recipients): Removed.
        (camel_mime_message_get_recipients): Return a camel-internet-address.
        (write_to_stream): No longer write receipients directly.
        (write_recipients_to_stream): Removed.
        (write_one_recipient_to_stream): Removed.
        (camel_mime_message_init): Setup recipients hashtable, rather than
        usign the recipients stuff.
        (set_recipient_list_from_string): Killed, a violent and lengthy
        death.
        (process_header): Simplified recipient handling code a lot.
        (received_date_str, sent_date_str, reply_to_str, subject_str,
        from_str): Removed some oddly-defined global statics.
        (camel_mime_message_class_init): Dont initialise above variables
        anymore.
        (init_header_name_table): Removed, use a table to init this, and
        do it in class init (2 lines of code ...).

        * camel-news-address.c: Class to represent news addresses -
        currently empty, and not built.

        * camel-internet-address.h: Class to represent internet (email)
        addresses.

        * camel-address.h: Abstract class to represent (lists of)
        addresses.

svn path=/trunk/; revision=2671
2000-04-28 03:06:44 +00:00
a39cd89c7d fix format specifier for time zone. Fix typo in month names array.
* camel-mime-utils.c (header_format_date): fix format specifier
	for time zone. Fix typo in month names array.

svn path=/trunk/; revision=2640
2000-04-26 19:53:49 +00:00
27937ec41f Big fixes for the last commit which broke the message creation entirely.
Plus an address decoder/formatter, etc.

	* camel-mime-message.c (construct_from_parser): Allow MESSAGE_END
	_or_ EOF as valid termination conditions.

	* providers/mbox/camel-mbox-summary.c (message_struct_new): Decode
	and then re-encode the addresses, so they are consistently
	formatted.

	* camel-mime-utils.c (header_decode_mailbox): Store the address in
	a _header_address.  And try to get a comment-stored name if there
	is one.
	(header_decode_address): Actually return an address.
	(header_to_decode): Renamed to header_address_decode()
	(header_mailbox_decode): New function to get a single mailbox.
	(header_mime_decode): Return the major/minor value, as
	appropriate.
	(header_address_new, and friends): Whole bunch of utility
	functions for working with the address thingies.
	(header_decode_domain): Free the string header, and dont expand
	'.' into ' . '.

	(camel_mime_part_construct_content_from_parser): Oops, this was
	totally screwed up, try creating the right cotnent on the right
	object.

svn path=/trunk/; revision=2579
2000-04-24 09:12:31 +00:00