platform/upstream/evolution-data-server.git
21 years agoRedirect program's stdout and stderr to /dev/null
Jeffrey Stedfast [Thu, 20 Feb 2003 19:11:18 +0000 (19:11 +0000)]
Redirect program's stdout and stderr to /dev/null

2003-02-20  Jeffrey Stedfast  <fejj@ximian.com>

* camel-filter-search.c (run_command): Redirect program's stdout
and stderr to /dev/null

* camel-filter-driver.c (pipe_to_system): Redirect the program's
stderr to /dev/null
(pipe_to_system): Write the pipe to a mem stream and use the mem
stream in the parser. Also, when setting an exception get the
errno from the parser so we can give more info about the error to
the user.

21 years agoRedirect the program's stderr to /dev/null
Jeffrey Stedfast [Thu, 20 Feb 2003 17:02:11 +0000 (17:02 +0000)]
Redirect the program's stderr to /dev/null

2003-02-20  Jeffrey Stedfast  <fejj@ximian.com>

* camel-filter-driver.c (pipe_to_system): Redirect the program's
stderr to /dev/null

21 years agouse argv[0] instead of argv[i], doh!
Jeffrey Stedfast [Thu, 20 Feb 2003 00:05:02 +0000 (00:05 +0000)]
use argv[0] instead of argv[i], doh!

21 years agoFixed a type-o in the ENABLE_IPv6 ifdef section.
Jeffrey Stedfast [Wed, 19 Feb 2003 23:44:00 +0000 (23:44 +0000)]
Fixed a type-o in the ENABLE_IPv6 ifdef section.

2003-02-19  Jeffrey Stedfast  <fejj@ximian.com>

* camel-tcp-stream-ssl.c (stream_connect): Fixed a type-o in the
ENABLE_IPv6 ifdef section.

21 years agoNew filter action that pipes the message source to the user-program and
Jeffrey Stedfast [Wed, 19 Feb 2003 22:38:55 +0000 (22:38 +0000)]
New filter action that pipes the message source to the user-program and

2003-02-19  Jeffrey Stedfast  <fejj@ximian.com>

* camel-filter-driver.c (pipe_message): New filter action that
pipes the message source to the user-program and reads back the
modified message and replaces driver->priv->message with the new
message object.
(do_copy): Check p->modified to make sure the message hasn't been
modified by the pipe-message action - if it has been modified,
default to the slower camel_folder_append_message() way of
copying.
(do_move): Same.
(pipe_to_system): Set p->modified to TRUE if the user-program gave
us back a message stream and we were able to parse it.
(camel_filter_driver_filter_message): If the message has been
modified, always use camel_folder_append_message() when appending
it to the default folder.

21 years agoNew filter action that pipes the message source to the user-program and
Jeffrey Stedfast [Wed, 19 Feb 2003 22:20:55 +0000 (22:20 +0000)]
New filter action that pipes the message source to the user-program and

2003-02-19  Jeffrey Stedfast  <fejj@ximian.com>

* camel-filter-driver.c (pipe_message): New filter action that
pipes the message source to the user-program and reads back the
modified message and replaces driver->priv->message with the new
message object.

21 years agoAdded a (get-size ) function to fix bug #38073. (search_get_size):
Jeffrey Stedfast [Fri, 14 Feb 2003 21:44:28 +0000 (21:44 +0000)]
Added a (get-size ) function to fix bug #38073. (search_get_size):

2003-02-14  Jeffrey Stedfast  <fejj@ximian.com>

* camel-folder-search.c: Added a (get-size ) function to fix bug
#38073.
(search_get_size): Implemented.

21 years agowatch for <>'s too
Jeffrey Stedfast [Fri, 14 Feb 2003 20:44:39 +0000 (20:44 +0000)]
watch for <>'s too

21 years agoMark chars with the high-bit set as CTRL chars. (camel_url_web_end): If
Jeffrey Stedfast [Fri, 14 Feb 2003 20:42:51 +0000 (20:42 +0000)]
Mark chars with the high-bit set as CTRL chars. (camel_url_web_end): If

2003-02-14  Jeffrey Stedfast  <fejj@ximian.com>

* camel-url-scanner.c (url_scanner_table_init): Mark chars with
the high-bit set as CTRL chars.
(camel_url_web_end): If the char before the start of the url is an
open-brace, watch out for the matching close-brace.
(camel_url_file_end): Same.

21 years agoSame as the gpg and pkcs7 contexts.
Jeffrey Stedfast [Fri, 14 Feb 2003 20:11:53 +0000 (20:11 +0000)]
Same as the gpg and pkcs7 contexts.

2003-02-14  Jeffrey Stedfast  <fejj@ximian.com>

* camel-smime-context.c (smime_get_password): Same as the gpg and
pkcs7 contexts.

* camel-sasl-popb4smtp.c (popb4smtp_challenge): Updated for
camel_session_get_password().

* camel-pkcs7-context.c (get_password): Same as the gpg code.

* camel-gpg-context.c (gpg_ctx_parse_status): Updated for
camel_session_get_password().

* providers/smtp/camel-smtp-transport.c (smtp_connect): No need to
set USER_CANCEL exception here as it is done by
camel_session_get_password(). Also updated for the new
get_password() API change.

* providers/imap/camel-imap-store.c (imap_auth_loop): Updated for
camel_session_get_password() changes. We don't need to play the
"bad passwd" game here too, do we? Bah, probably should but I
don't feel like it for now. Maybe when we rewrite the IMAP
provider.

* camel-session.c (camel_session_get_password): Now takes a
'reprompt' argument that will force user-input to be given even if
we have the passwd cached.

* providers/pop3/camel-pop3-store.c (pop3_connect): Instead of
uncaching the passwd after we receive a -ERR from the POP server,
set 'reprompt' to TRUE to force user-input for the next password
prompt (ie, make sure the front-end knows not to just return the
cached value). The front-end can then decide to fill-in the
user-input field with the last passwd that the user supplied.
(pop3_try_authenticate): Now takes a reprompt argument which we
pass into camel_session_get_password().

21 years agoDefine in terms of privincludedir. (camellibexecdir): Define in terms of
Dan Winship [Wed, 5 Feb 2003 22:34:18 +0000 (22:34 +0000)]
Define in terms of privincludedir. (camellibexecdir): Define in terms of

* Makefile.am (libcamelincludedir): Define in terms of
privincludedir.
(camellibexecdir): Define in terms of privlibexecdir
(libcamel_la_LDFLAGS): Remove -rpath. (automake will add that)

* providers/imap/Makefile.am (libcamelimapincludedir): Define in
terms of privincludedir.
(INCLUDES): Remove -I$(includedir)
* providers/local/Makefile.am: Likewise
* providers/nntp/Makefile.am: Likewise
* providers/pop3/Makefile.am: Likewise
* providers/sendmail/Makefile.am: Likewise
* providers/smtp/Makefile.am: Likewise

21 years agodefine in terms of privincludedir.
Dan Winship [Wed, 5 Feb 2003 21:58:38 +0000 (21:58 +0000)]
define in terms of privincludedir.

* Makefile.am (eutilincludedir, etc): define in terms of
privincludedir.

* ename/Makefile.am (libenameincludedir): Likewise

* e-account.c: Fix warnings
* e-account-list.c: Likewise
* e-config-listener.c: Likewise
* e-gui-utils.c: Likewise.
* e-lang-utils.c: Likewise
* e-msgport.c: Likewise
* e-passwords.c: Likewise

* e-categories-config.c
(e_categories_config_open_dialog_for_entry): Use g_object_get/_set
rather than gtk_

* e-url.c (e_uri_new): Use g_ascii_strdown instead of deprecated
g_strdown.

21 years agoInit bag->owner to 0.
Not Zed [Wed, 5 Feb 2003 04:53:53 +0000 (04:53 +0000)]
Init bag->owner to 0.

2003-02-04  Not Zed  <NotZed@Ximian.com>

        * camel-object.c (camel_object_bag_new): Init bag->owner to 0.

2003-01-31  Not Zed  <NotZed@Ximian.com>

        * camel-object.c (camel_object_bag_*): Changed to use a posix
        semaphore instead of a condition variable + flag to reserve the
        object bag because e_mutex_cond is broken.

21 years agoUse g_ascii_strdown() instead of g_strdown, since g_strdown is deprecated.
Jeffrey Stedfast [Tue, 4 Feb 2003 23:36:01 +0000 (23:36 +0000)]
Use g_ascii_strdown() instead of g_strdown, since g_strdown is deprecated.

2003-02-04  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-utils.c (imap_parse_body): Use
g_ascii_strdown() instead of g_strdown, since g_strdown is
deprecated.
(imap_parse_body): Same.

* providers/imap/camel-imap-folder.c (decode_internaldate): Use
strncasecmp() here too.
(parse_fetch_response): And here.
(camel_imap_folder_selected): Here too.

* providers/imap/camel-imap-utils.c (imap_namespace_decode): Use
strncasecmp() instead of g_strncasecmp() because the latter is
deprecated.

* providers/imap/camel-imap-store.c (imap_get_capability): Again here.
(hash_folder_name): Here too.
(compare_folder_name): And here.
(get_folder_online): Again.
(get_folder_offline): And again.

* providers/imap/camel-imap-folder.c (camel_imap_folder_selected):
Same as below again.

* providers/imap/camel-imap-command.c (camel_imap_response_free):
Same as below.

* providers/smtp/camel-smtp-transport.c (smtp_data): Use
strcasecmp() because g_strcasecmp() is deprecated.

* camel-url.c (camel_url_new_with_base): Use g_ascii_strdown()
instead of g_strdown, since g_strdown is deprecated.

2003-01-28  Jeffrey Stedfast  <fejj@ximian.com>

* camel-sasl-gssapi.c (gssapi_challenge): Pass in some default
flags to gss_init_sec_context() (these default flags are defined
as a MUST in rfc1964).

21 years agoPass in some default flags to gss_init_sec_context() (these default flags
Jeffrey Stedfast [Tue, 28 Jan 2003 23:58:32 +0000 (23:58 +0000)]
Pass in some default flags to gss_init_sec_context() (these default flags

2003-01-28  Jeffrey Stedfast  <fejj@ximian.com>

* camel-sasl-gssapi.c (gssapi_challenge): Pass in some default
flags to gss_init_sec_context() (these default flags are defined
as a MUST in rfc1964).

21 years ago$(libexec) -> $(libexecdir)
Hans Petter Jansson [Wed, 22 Jan 2003 21:33:04 +0000 (21:33 +0000)]
$(libexec) -> $(libexecdir)

2003-01-22  Hans Petter Jansson  <hpj@ximan.com>

* Makefile.am: $(libexec) -> $(libexecdir)

21 years agoUpdate to the new $(BASE_VERSION)-versioned path. Likewise. Likewise.
Ettore Perazzoli [Wed, 22 Jan 2003 20:08:56 +0000 (20:08 +0000)]
Update to the new $(BASE_VERSION)-versioned path. Likewise. Likewise.

* providers/imap/Makefile.am (libcamelimapincludedir): Update to
the new $(BASE_VERSION)-versioned path.
* providers/smtp/Makefile.am (libcamelsmtpincludedir): Likewise.
* providers/sendmail/Makefile.am (libcamelsendmailincludedir):
Likewise.
* providers/pop3/Makefile.am (libcamelpop3includedir): Likewise.
* providers/nntp/Makefile.am (libcamelnntpincludedir): Likewise.
* providers/local/Makefile.am (libcamellocalincludedir): Likewise.

* camel-lock-client.c (camel_lock_helper_init): Use
CAMEL_LIBEXECDIR instead of CAMEL_SBINDIR to find
camel-lock-helper.

* Makefile.am: Install camel-lock-helper and camel-index-control
in $(libexec)/evolution/$(BASE_VERSION)/camel.  Install
libcamel.la in $privlibdir.
(install-exec-hook): Update for the new location of
camel-lock-helper.
(libcamelincludedir): Version using $(BASE_VERSION).
(INCLUDES): Define CAMEL_LIBEXECDIR.

21 years agoSet the backbuflen to 0 so that calling us again won't re-flush the same
Jeffrey Stedfast [Tue, 21 Jan 2003 16:38:53 +0000 (16:38 +0000)]
Set the backbuflen to 0 so that calling us again won't re-flush the same

2003-01-21  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-filter-canon.c (complete): Set the backbuflen to 0 so
that calling us again won't re-flush the same data.

21 years agoonly grow the buffer when we are out of space.
Larry Ewing [Sat, 18 Jan 2003 03:59:55 +0000 (03:59 +0000)]
only grow the buffer when we are out of space.

2003-01-17  Larry Ewing  <lewing@ximian.com>

* camel-mime-filter-enriched.c (enriched_to_html): only grow the
buffer when we are out of space.

21 years agoIf we have no content-type header, set it to text/plain explcitly, rather
Not Zed [Tue, 14 Jan 2003 07:15:27 +0000 (07:15 +0000)]
If we have no content-type header, set it to text/plain explcitly, rather

2003-01-14  Not Zed  <NotZed@Ximian.com>

        * camel-mime-parser.c (folder_scan_step): If we have no
        content-type header, set it to text/plain explcitly, rather than
        NULL, because some code doesn't handle NULL.

21 years agoNew source files implementing the GSSAPI SASL mechanism.
Jeffrey Stedfast [Tue, 14 Jan 2003 05:48:08 +0000 (05:48 +0000)]
New source files implementing the GSSAPI SASL mechanism.

2003-01-14  Jeffrey Stedfast  <fejj@ximian.com>

* camel-sasl-gssapi.[c,h]: New source files implementing the
GSSAPI SASL mechanism.

21 years agofix header include order.
Not Zed [Mon, 13 Jan 2003 11:56:12 +0000 (11:56 +0000)]
fix header include order.

2003-01-13  Not Zed  <NotZed@Ximian.com>

        * camel-mime-filter-tohtml.c: fix header include order.

        * camel-object.c (camel_object_bag_reserve): Add an assert to
        check we're not trying to reserve the bag more than once in a
        given thread.
        (camel_object_bag_list): If we have reserved the bag, dont try and
        cond wait.  Fixes a deadlock.

21 years agoRead the characters as utf8, rather than as 8 bit bytes. Remove the
Not Zed [Mon, 13 Jan 2003 05:46:35 +0000 (05:46 +0000)]
Read the characters as utf8, rather than as 8 bit bytes. Remove the

2003-01-13  Not Zed  <NotZed@Ximian.com>

        * camel-mime-filter-tohtml.c (writeln): Read the characters as
        utf8, rather than as 8 bit bytes.  Remove the PRESERVE_8BIT as it
        has no meaning.  Also change the default logic slightly so that 8
        bit or greater characters are properly converted to entities.

        * camel-utf8.c (camel_utf8_getc_limit): new function, gets a utf8
        char, bounded by an end pointer.

21 years agoadd a "translation_domain" field. (NULL for all providers in the camel
Dan Winship [Tue, 7 Jan 2003 21:03:56 +0000 (21:03 +0000)]
add a "translation_domain" field. (NULL for all providers in the camel

* camel-provider.h (CamelProvider): add a "translation_domain"
field. (NULL for all providers in the camel source tree itself).

* camel-session.c (register_provider): Translate provider strings
in the correct domain

21 years agoNew.
Dan Winship [Tue, 7 Jan 2003 15:04:07 +0000 (15:04 +0000)]
New.

* e-config-listener.c (e_config_listener_remove_value): New.

* e-passwords.c (e_passwords_get_password): Don't look at the
passwords hash until calling e_passwords_init().

21 years agoinit local exception before doing anything. fixes a crash.
Not Zed [Sun, 5 Jan 2003 23:48:10 +0000 (23:48 +0000)]
init local exception before doing anything. fixes a crash.

2003-01-06  Not Zed  <NotZed@Ximian.com>

* camel-store.c (store_sync): init local exception before doing
anything.  fixes a crash.

21 years agospell-check
Jeffrey Stedfast [Sun, 5 Jan 2003 01:23:55 +0000 (01:23 +0000)]
spell-check

21 years agoInstead of checking recipients != NULL, check that camel_address_length
Jeffrey Stedfast [Sat, 4 Jan 2003 22:50:01 +0000 (22:50 +0000)]
Instead of checking recipients != NULL, check that camel_address_length

2003-01-04  Jeffrey Stedfast  <fejj@ximian.com>

* providers/smtp/camel-smtp-transport.c (smtp_send_to): Instead of
checking recipients != NULL, check that camel_address_length
(recipients) != 0 since it is illegal for recipients to be NULL
(camel_transport_send_to already checks this).

21 years agocommit this too
Jeffrey Stedfast [Tue, 17 Dec 2002 21:48:23 +0000 (21:48 +0000)]
commit this too

21 years agoReplace calls to g_string_sprintfa() with g_string_append_printf() since
Jeffrey Stedfast [Tue, 17 Dec 2002 21:46:44 +0000 (21:46 +0000)]
Replace calls to g_string_sprintfa() with g_string_append_printf() since

2002-12-17  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-utils.c: Replace calls to
g_string_sprintfa() with g_string_append_printf() since the former
seems to have been deprecated.

* providers/imap/camel-imap-search.c: Same.

* providers/imap/camel-imap-folder.c: Here too.

* providers/local/camel-mbox-summary.c: And here.

* providers/local/camel-local-summary.c: Replace
g_string_sprintf() with g_string_printf().

* camel-data-cache.c (data_cache_expire): Replace
g_string_sprintf() with g_string_printf().

* camel-url.c: Replace calls to g_string_sprintfa() with
g_string_append_printf() since the former seems to have been
deprecated.

* camel-service.c: Same.

* camel-mime-utils.c: Here too.

21 years agoReplace calls to g_string_sprintfa() with g_string_append_printf() since
Jeffrey Stedfast [Tue, 17 Dec 2002 21:01:00 +0000 (21:01 +0000)]
Replace calls to g_string_sprintfa() with g_string_append_printf() since

2002-12-17  Jeffrey Stedfast  <fejj@ximian.com>

* camel-url.c: Replace calls to g_string_sprintfa() with
g_string_append_printf() since the former seems to have been
deprecated.

* camel-service.c: Same.

* camel-mime-utils.c: Here too.

21 years agoDetect text/html parts that were marked as text/plain and re-tag them as
Jeffrey Stedfast [Mon, 16 Dec 2002 23:45:41 +0000 (23:45 +0000)]
Detect text/html parts that were marked as text/plain and re-tag them as

2002-12-16  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-part-utils.c
(simple_data_wrapper_construct_from_parser): Detect text/html
parts that were marked as text/plain and re-tag them as text/html
parts. Note: currently just checks if the first non-lwsp char is a
'<' - but we might need to be smarter about this? *sigh* Stupid
Windows mailers.

21 years agoNew convenience function to replace calls to e_text_to_html() in the
Jeffrey Stedfast [Mon, 16 Dec 2002 19:36:35 +0000 (19:36 +0000)]
New convenience function to replace calls to e_text_to_html() in the

2002-12-16  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-filter-tohtml.c (camel_text_to_html): New convenience
function to replace calls to e_text_to_html() in the
mailer/composer etc.

21 years ago#include some headers we had forgotten to add previously, also added
Jeffrey Stedfast [Mon, 16 Dec 2002 15:05:06 +0000 (15:05 +0000)]
#include some headers we had forgotten to add previously, also added

2002-12-16  Jeffrey Stedfast  <fejj@ximian.com>

* camel.h: #include some headers we had forgotten to add
previously, also added camel-mime-filter-enriched.h.

* camel-mime-filter-enriched.[c,h]: New stream filter to convert
text/enriched and text/richtext into HTML.

21 years agoDon't apply the CANON_STRIP filter here, since we are verifying whatever
Jeffrey Stedfast [Mon, 16 Dec 2002 00:52:25 +0000 (00:52 +0000)]
Don't apply the CANON_STRIP filter here, since we are verifying whatever

2002-12-15  Jeffrey Stedfast  <fejj@ximian.com>

* camel-multipart-signed.c (camel_multipart_signed_verify): Don't
apply the CANON_STRIP filter here, since we are verifying whatever
raw data we received (all we want to do is convert o the canonical
CRLF format).

21 years agoUse camel-url-scanner instead of regex.
Jeffrey Stedfast [Tue, 10 Dec 2002 17:40:34 +0000 (17:40 +0000)]
Use camel-url-scanner instead of regex.

2002-12-10  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-filter-tohtml.c (html_convert): Use camel-url-scanner
instead of regex.

21 years agoFixed to not be fooled in the case where the address is followed
Jeffrey Stedfast [Tue, 10 Dec 2002 03:44:17 +0000 (03:44 +0000)]
Fixed to not be fooled in the case where the address is followed

2002-12-09  Jeffrey Stedfast  <fejj@ximian.com>

* camel-url-scanner.c (camel_url_addrspec_end): Fixed to not be
fooled in the case where the address is followed immediately by a
period.
(camel_url_web_end): Made more robust.
(camel_url_scanner_scan): Oops. We need to set the match->pattern
string pointer to the correct pattern before executing the
start/end methods (as some of them rely on this info).

21 years agoNew code to scan for patterns (used only for url pattern matching atm, but
Jeffrey Stedfast [Mon, 9 Dec 2002 23:18:31 +0000 (23:18 +0000)]
New code to scan for patterns (used only for url pattern matching atm, but

2002-12-09  Jeffrey Stedfast  <fejj@ximian.com>

* camel-url-scanner.c: New code to scan for patterns (used only
for url pattern matching atm, but we may find other uses for this
and thus rename it? I dunno). Uses ETrie.

21 years agotrack changes to api (e_passwords_init is gone, and several functions take
Chris Toshok [Mon, 9 Dec 2002 21:39:41 +0000 (21:39 +0000)]
track changes to api (e_passwords_init is gone, and several functions take

2002-12-09  Chris Toshok  <toshok@ximian.com>

* e-passwords.h: track changes to api (e_passwords_init is gone,
and several functions take the component name as an arg.)

* e-passwords.c (e_passwords_init): make this static, and allow
multiple calls.  Also, it no longer takes the component name.
(e_passwords_shutdown): make this deal with the case where
e_passwords_init wasn't called (no hashtable), and it no longer
needs to free component_name.
(e_passwords_forget_passwords): call e_passwords_init.
(e_passwords_clear_component_passwords): take component_name as an
arg, and call e_passwords_init.
(password_path): take component_name as an arg.
(e_passwords_remember_password): same, and call e_passwords_init.
(e_passwords_forget_password): same.
(e_passwords_get_password): same.
(e_passwords_add_password): call e_passwords_init.
(e_passwords_ask_password): take component_name as an arg.

21 years agoUse a bag instead of a hashtable to track the cache streams.
Not Zed [Mon, 9 Dec 2002 00:28:06 +0000 (00:28 +0000)]
Use a bag instead of a hashtable to track the cache streams.

2002-12-07  Not Zed  <NotZed@Ximian.com>

* camel-data-cache.c (data_cache_init): Use a bag instead of a
hashtable to track the cache streams.
(data_cache_finalise): Same.
(free_busy): No longer needed.
(data_cache_expire): use bag instead of hashtable.
(stream_finalised): No longer required.
(camel_data_cache_add): objectbagise
(camel_data_cache_get): "
(camel_data_cache_remove): "
(data_cache_path): Set the now expired date before running expiry,
so it plays better with multiple threads.  Still a couple of
harmless races.

2002-12-06  Not Zed  <NotZed@Ximian.com>

* providers/local/camel-spool-store.c (scan_dir): folders ->
object bag.
(get_folder_info_mbox): folders -> object bag.

* providers/local/camel-mh-store.c (folder_info_new): folders ->
object bag.

* providers/local/camel-maildir-store.c (scan_dir): folders ->
object bag.

* providers/local/camel-local-store.c (rename_folder): folders ->
object bag.

* camel-private.h (CamelStorePrivate): Remove 'cache' lock,
handled by the objectbag.

* providers/imap/camel-imap-store.c (copy_folder): Removed.
(imap_store_refresh_folders): folders -> object bag.
(get_folder_counts): folders -> object bag.

* camel-vee-store.c (vee_get_folder): changes for folders
objectbag.
(vee_get_folder_info): Change to use folders objectbag.  Also,
dont refresh the base folder if we're in FAST mode.
(build_info): Removed, no longer needed.
(vee_rename_folder): Fixed for folders objectbag.

* camel-store.c (camel_store_init): init the folders objectbag.
(camel_store_finalize): Destroy the folders object bag.
(folder_matches):
(folder_finalize): Removed, now handled implicitly by the
objectbag.
(camel_store_get_folder): object bag changes.
(camel_store_delete_folder): "
(get_subfolders): Removed, now handled without a callback.
(camel_store_rename_folder): Changed to use object bag of folders.
(trash_add_folder): Removed.
(init_trash): use folders object bag.
(copy_folder_cache):
(sync_folder): Removed, no longer needed.  Weird arsed code anyway.
(store_sync): Use folder object bag instead of hashtable.
(camel_store_unsubscribe_folder): "
(camel_store_init): remove cache_lock init, no longer used.
(camel_store_finalize): Same for cleanup.

2002-12-05  Not Zed  <NotZed@Ximian.com>

* camel-store.h (struct _CamelStore): change folders from a
hashtable into a CamelObjectBag.

* camel-object.c (camel_object_ref): Use type_lock instead of
class lock for ref counting.
(camel_object_unref): Use type_lock instead of class lock for
unref.
(camel_object_unref): If the object is 'bagged', then also look
hooks, and remove it from any bags.
(camel_object_bag_new):
(camel_object_bag_destroy):
(camel_object_bag_add):
(camel_object_bag_get):
(camel_object_bag_remove_unlocked):
(camel_object_bag_list):
(camel_object_bag_abort):
(camel_object_bag_remove): New functions to implement a utility
object which can manage a 'bag' of weakly ref'd children in an
atomic & threadsafe way.

21 years agoProperly handle the case where the namespace is "". Fixes bug #34975
Jeffrey Stedfast [Wed, 4 Dec 2002 16:17:02 +0000 (16:17 +0000)]
Properly handle the case where the namespace is "". Fixes bug #34975

2002-12-04  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-store-summary.c
(camel_imap_store_summary_add_from_full): Properly handle the case
where the namespace is "". Fixes bug #34975

21 years agoFixed to not get false positives when the token is shorter than the actual
Jeffrey Stedfast [Tue, 3 Dec 2002 18:23:17 +0000 (18:23 +0000)]
Fixed to not get false positives when the token is shorter than the actual

2002-12-03  Jeffrey Stedfast  <fejj@ximian.com>

* broken-date-parser.c (get_tzone): Fixed to not get false
positives when the token is shorter than the actual timezone
string (but matches the first little bit of it).
(datetok): Modified to properly handle when the first char of a
token is a special char (such as a '-') that is also used as a
token delimiter.

21 years agoUse the new camel_operation_cancel_prfd() function to get the cancellation
Jeffrey Stedfast [Fri, 22 Nov 2002 22:29:56 +0000 (22:29 +0000)]
Use the new camel_operation_cancel_prfd() function to get the cancellation

2002-11-21  Jeffrey Stedfast  <fejj@ximian.com>

* camel-tcp-stream-ssl.c (stream_read): Use the new
camel_operation_cancel_prfd() function to get the cancellation fd
so we can poll on it for cancellation stuff.
(stream_write): Same.

2002-11-22  Not Zed  <NotZed@Ximian.com>

* camel-operation.c (camel_operation_cancel_prfd): Implement, gets
a nspr pr filedesc to poll/wait on
(struct _CamelOperation): include a pr filedesc.

21 years agoIf we have a namespace of "", then always match any path.
Not Zed [Fri, 22 Nov 2002 03:12:10 +0000 (03:12 +0000)]
If we have a namespace of "", then always match any path.

2002-11-21  Not Zed  <NotZed@Ximian.com>

        * providers/imap/camel-imap-store-summary.c
        (camel_imap_store_summary_namespace_find_path): If we have a
        namespace of "", then always match any path.
        (camel_imap_store_summary_namespace_find_full): Same, for full
        names. Should address #33309 & friends.

21 years agoapplied plain_signature_fix.patch
Radek Doulik [Tue, 19 Nov 2002 18:42:39 +0000 (18:42 +0000)]
applied plain_signature_fix.patch

21 years agoRemoved $(GNOME_LIBDIR) and $(GNOMEUI_LIBS)
Rodney Dawes [Tue, 19 Nov 2002 17:21:44 +0000 (17:21 +0000)]
Removed $(GNOME_LIBDIR) and $(GNOMEUI_LIBS)

* tests/*/Makefile.am: Removed $(GNOME_LIBDIR) and $(GNOMEUI_LIBS)

21 years agoIf the namespace is at/below INBOX, check for the INBOX explicitly (since
Jeffrey Stedfast [Mon, 18 Nov 2002 13:23:32 +0000 (13:23 +0000)]
If the namespace is at/below INBOX, check for the INBOX explicitly (since

2002-11-15  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-store.c (imap_connect_online): If the
namespace is at/below INBOX, check for the INBOX explicitly (since
it obviously won't show up in a LSUB INBOX.*). If either INBOX is
not returned in the response or if the folder flags contain
\NoSelect, subscribe to INBOX and then try LSUB again.

21 years agoadd e-password.h (libeutil_la_SOURCES): add e-password.c
Chris Toshok [Tue, 12 Nov 2002 23:05:06 +0000 (23:05 +0000)]
add e-password.h (libeutil_la_SOURCES): add e-password.c

2002-11-12  Chris Toshok  <toshok@ximian.com>

* Makefile.am
(eutilinclude_HEADERS): add e-password.h
(libeutil_la_SOURCES): add e-password.c

* e-passwords.[ch]: port this to gnome2's gnome-config-private.

21 years agoRewritten. Much much much cleaner implementation now, though uses
Jeffrey Stedfast [Mon, 11 Nov 2002 15:14:49 +0000 (15:14 +0000)]
Rewritten. Much much much cleaner implementation now, though uses

2002-11-11  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-filter-tohtml.c (html_convert): Rewritten. Much much
much cleaner implementation now, though uses malloc/free more
often than I'd like.

21 years agoUse g_strerror when setting an exception string (we need it to be in
Jeffrey Stedfast [Mon, 11 Nov 2002 06:40:28 +0000 (06:40 +0000)]
Use g_strerror when setting an exception string (we need it to be in

2002-11-11  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-folder.c (get_message_simple): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).

* providers/pop3/camel-pop3-store.c (pop3_try_authenticate): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).

* providers/pop3/camel-pop3-folder.c (pop3_refresh_info): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).
(pop3_get_message): Same.

21 years agoUse g_strerror when setting an exception string (we need it to be in
Jeffrey Stedfast [Mon, 11 Nov 2002 06:24:56 +0000 (06:24 +0000)]
Use g_strerror when setting an exception string (we need it to be in

2002-11-11  Jeffrey Stedfast  <fejj@ximian.com>

* providers/local/camel-spool-summary.c (spool_summary_sync_full):
Use g_strerror when setting an exception string (we need it to be
in UTF-8).
(spool_summary_check): Here too.

* providers/local/camel-spool-store.c (construct): Use g_strerror
when setting an exception string (we need it to be in UTF-8).
(get_folder): Same.
(scan_dir): Here too.

* providers/local/camel-spool-folder.c (spool_lock): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).

* providers/local/camel-mh-summary.c (mh_summary_check): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).

* providers/local/camel-mh-store.c (delete_folder): Use g_strerror
when setting an exception string (we need it to be in UTF-8).

* providers/local/camel-mbox-summary.c (summary_update): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).
(mbox_summary_sync_full): Here too.
(mbox_summary_sync_quick): Same.
(mbox_summary_sync): Also here.
(camel_mbox_summary_sync_mbox): Again here.

* providers/local/camel-mbox-folder.c (mbox_lock): Use g_strerror
when setting an exception string (we need it to be in UTF-8).
(mbox_append_message): Same.
(mbox_get_message): Here too.

* providers/local/camel-maildir-summary.c (maildir_summary_load):
Use g_strerror when setting an exception string (we need it to be
in UTF-8).
(maildir_summary_check): Same.

* providers/local/camel-maildir-store.c (get_folder): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).
(delete_folder): Same.
(delete_folder): Here too.

* providers/local/camel-local-summary.c (local_summary_sync): Use
g_strerror when setting an exception string (we need it to be in
UTF-8).

* providers/local/camel-local-store.c (get_folder): Use g_strerror
when setting an exception string (we need it to be in UTF-8).
(create_folder): Same.
(xrename): Here too.
(rename_folder): And here.
(delete_folder): Also here.

* camel-provider.c (camel_provider_init): For debugging printfs,
we want to use normal strerror (we want locale charset, not
UTF-8).

* camel-movemail.c (camel_movemail): Use g_strerror when setting
an exception string (we need it to be in UTF-8).
(movemail_external): Same.
(camel_movemail_copy_file): Here too.
(camel_movemail_solaris): Also here.

* camel-mime-utils.c (rfc2047_decode_word): For debugging printfs,
we want to use normal strerror (we want locale charset, not
UTF-8).
(header_encode_param): Same.

* camel-mime-part-utils.c (convert_buffer): For debugging printfs,
we want to use normal strerror (we want locale charset, not
UTF-8).

* camel-lock-client.c (camel_lock_helper_init): Use g_strerror
when setting an exception string (we need it to be in UTF-8).

* camel-data-cache.c (camel_data_cache_remove): Use g_strerror
when setting an exception string (we need it to be in UTF-8).

* camel-tcp-stream-raw.c (flaky_tcp_write): For debugging printfs,
we want to use normal strerror (we want locale charset, not
UTF-8).
(flaky_tcp_read): Same.

* camel-gpg-context.c (gpg_ctx_op_step): For debugging printfs, we
want to use normal strerror (we want locale charset, not UTF-8).

* camel-service.c (camel_gethostbyname): Use g_strerror when
setting an exception string (we need it to be in UTF-8).

* camel-lock.c (camel_lock_dot): Use g_strerror when setting an
exception string (we need it to be in UTF-8).
(camel_lock_fcntl): Same.

21 years agoconstify the content_type.
Not Zed [Fri, 8 Nov 2002 06:59:12 +0000 (06:59 +0000)]
constify the content_type.

2002-11-07  Not Zed  <NotZed@Ximian.com>

        * camel-mime-part.c (camel_mime_part_set_content_type): constify
        the content_type.

21 years agodon't #include <gtk/gtk.h>
Jeffrey Stedfast [Thu, 7 Nov 2002 21:49:25 +0000 (21:49 +0000)]
don't #include <gtk/gtk.h>

21 years agoAdded.
Jeffrey Stedfast [Thu, 7 Nov 2002 21:34:17 +0000 (21:34 +0000)]
Added.

2002-11-07  Jeffrey Stedfast  <fejj@ximian.com>

* camel-i18n.h: Added.

* camel-object.h: #include camel-i18n.h instead of gnome-i18n.h

* camel-lock.c: Same.

21 years agoremoved gnome-defs.h, it does not exist.
Rodrigo Moya [Thu, 7 Nov 2002 16:34:33 +0000 (16:34 +0000)]
removed gnome-defs.h, it does not exist.

2002-11-07  Rodrigo Moya <rodrigo@ximian.com>

* camel-object.h: removed gnome-defs.h, it does not exist.

21 years agoCreated temporary link list, we need to link with something for gettext.
Not Zed [Tue, 5 Nov 2002 09:05:24 +0000 (09:05 +0000)]
Created temporary link list, we need to link with something for gettext.

2002-11-05  Not Zed  <NotZed@Ximian.com>

* Makefile.am (camel_lock_helper_LDADD): Created temporary link
list, we need to link with something for gettext.

* camel.h: Remove gstring-util.h and hash-table-utils.h.

* camel-text-index.c:
(text_index_normalise): Changed for g_utf8_strdown api change.

* camel-search-private.c:
* camel-mime-utils.c:
* camel-mime-part-utils.c:
* camel-html-parser.c:
* camel-charset-map.c: Include glib/gunicode.h from glib instead
of gal.

* camel-filter-driver.c: Remove include of gtk/gtk.h, should never
have been there.

21 years agoRemoved. Glib2 has this function.
Jeffrey Stedfast [Sat, 2 Nov 2002 00:59:16 +0000 (00:59 +0000)]
Removed. Glib2 has this function.

2002-11-01  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-utils.c (g_string_append_len): Removed. Glib2 has
this function.

21 years agoUse g_path_get_basename instead of g_strdup (g_basename (filename)).
Jeffrey Stedfast [Sat, 2 Nov 2002 00:45:29 +0000 (00:45 +0000)]
Use g_path_get_basename instead of g_strdup (g_basename (filename)).

2002-11-01  Jeffrey Stedfast  <fejj@ximian.com>

* providers/local/camel-local-store.c (delete_folder): Use
g_path_get_basename instead of g_strdup (g_basename (filename)).

21 years agoUse g_path_get_dirname since g_dirname has been deprecated.
Jeffrey Stedfast [Sat, 2 Nov 2002 00:42:07 +0000 (00:42 +0000)]
Use g_path_get_dirname since g_dirname has been deprecated.

2002-11-01  Jeffrey Stedfast  <fejj@ximian.com>

* camel-uid-cache.c (camel_uid_cache_new): Use g_path_get_dirname
since g_dirname has been deprecated.

21 years agoSet the virtual method pointers to the import/export methods.
Jeffrey Stedfast [Fri, 1 Nov 2002 00:45:05 +0000 (00:45 +0000)]
Set the virtual method pointers to the import/export methods.

2002-10-31  Jeffrey Stedfast  <fejj@ximian.com>

* camel-gpg-context.c (camel_gpg_context_class_init): Set the
virtual method pointers to the import/export methods.
(camel_gpg_context_init): Set the key_protocol string.
(gpg_hash_to_id): Handle 2 more hash types.
(gpg_id_to_hash): Same.
(gpg_ctx_op_step): Slight fixes to support import/export.
(gpg_ctx_parse_status): Fix to hack around the fact that importing
keys doesn't write to stdout.
(gpg_import_keys): Implemented.
(gpg_export_keys): Implemented.

* camel-cipher-context.c (camel_cipher_context_class_init): Hook
up default virtual methods for import/export.
(camel_cipher_import_keys): Implemented.
(camel_cipher_export_keys): Implemented.

21 years agooops, commit this too
Jeffrey Stedfast [Thu, 31 Oct 2002 21:57:43 +0000 (21:57 +0000)]
oops, commit this too

21 years agoRemoved hash-table-utils.[c,h] from the build.
Jeffrey Stedfast [Thu, 31 Oct 2002 21:57:29 +0000 (21:57 +0000)]
Removed hash-table-utils.[c,h] from the build.

2002-10-31  Jeffrey Stedfast  <fejj@ximian.com>

* Makefile.am: Removed hash-table-utils.[c,h] from the build.

* hash-table-utils.[c,h]: Removed.

* string-util.c: Imported g_strcase[hash,equal] into here so we
can remove hash-table-utils.[c,h].

* camel-medium.c: Removed #include "hash-table-utils.h"

* camel-mime-message.c: Same here.

* camel-mime-part.c: And here.

* camel-session.c: Here too.

* providers/imap/camel-imap-store-summary.c: #include
string-utils.h instead of hash-table-utils.h

* camel-charset-map.c: Same.

* camel-folder-summary.c: Here too.

* camel-provider.c: Again here.

* camel-store-summary.c: And again...

21 years agoRemove a ton of useless snot.
Jeffrey Stedfast [Thu, 31 Oct 2002 21:41:26 +0000 (21:41 +0000)]
Remove a ton of useless snot.

2002-10-31  Jeffrey Stedfast  <fejj@ximian.com>

Remove a ton of useless snot.

* Makefile.am: Remove gstring-util.[c,h] from the build.

* gstring-util.[c,h]: Removed.

* string-utils.c (string_equal_for_glist): Removed.
(string_split): Removed.
(string_trim): Removed.
(string_prefix): Removed.
(string_unquote): Removed.
(strip): Removed.

* hash-table-utils.c (g_hash_table_generic_free): Removed.

g_str[n]casecmp functions are deprecated in glib2.

* string-utils.c (strstrcase): Use strncasecmp instead of
g_strncasecmp.

* hash-table-utils.c (g_strcase_equal): Use strcasecmp
instead of g_strcasecmp.

* camel-smime-utils.c (camel_smime_is_smime_v3_signed): Same.
(camel_smime_is_smime_v3_encrypted): Here too.

* camel-sasl-digest-md5.c (decode_data_type): And here.
(parse_server_challenge): Again here.

* camel-pgp-mime.c (camel_pgp_mime_is_rfc2015_signed): Same.
(camel_pgp_mime_is_rfc2015_encrypted): Same

* camel-mime-part-utils.c (check_html_charset): Here too.

* camel-folder-summary.c (camel_system_flag): Same.

21 years agoDon't prematurely set gpg->complete to TRUE. Let gpg_ctx_op_step () set it
Jeffrey Stedfast [Mon, 28 Oct 2002 01:43:08 +0000 (01:43 +0000)]
Don't prematurely set gpg->complete to TRUE. Let gpg_ctx_op_step () set it

2002-10-25  Jeffrey Stedfast  <fejj@ximian.com>

* camel-gpg-context.c (gpg_ctx_parse_status): Don't prematurely
set gpg->complete to TRUE. Let gpg_ctx_op_step () set it to TRUE
when gpg closes the status-fd instead.

21 years ago** For bug #31647 and bug #31456.
Not Zed [Thu, 24 Oct 2002 14:01:53 +0000 (14:01 +0000)]
** For bug #31647 and bug #31456.

2002-10-24  Not Zed  <NotZed@Ximian.com>

        ** For bug #31647 and bug #31456.

        * camel-store-summary.c (store_info_string): for STORE_INFO_NAME,
        skip the leading /.

        * providers/imap/camel-imap-store.c
        (parse_list_response_as_folder_info): Remove jeff's last patch,
        and use the store summary to create the name and path of the
        folderinfo so it manages namespace issues.
        (get_folder_info_online): Just pass @top directly to
        build_folder_info always, since namespace is mapped to 1 tree
        level.
        (imap_build_folder_info): Remove jeff's last patch, dont strip
        leading /'s, they shouldn't exist.
        (imap_connect_online): Remove adding the INBOX here, we add it
        later.
        (get_subscribed_folders): Make sure INBOX is always in the list.
        some imap servers dont seem to let you subscribe to it(?), so
        always have it act as subscribed.

        * camel-store.c (camel_folder_info_build): back out the last 2
        patches from Jeff (for #31456) to get the original behaviour.
        (camel_folder_info_build): When creating a fake
        parent, dont strip the namespace from the full_name.  malloc keys
        in hash since we dont have them anymore.
        (free_name): Helper to free names.

        * providers/imap/camel-imap-store-summary.c
        (camel_imap_store_summary_namespace_new): Canonicalise the
        namespace (strip trailing dir_sep), and change the path to remove
        any /'s.
        (camel_imap_store_summary_namespace_find_path):
        (camel_imap_store_summary_namespace_find_full): new, find
        namespace by path/full name.
        (camel_imap_store_summary_full_from_path): Changed to a simple
        wrapper around path_to_full, after checking namespace.
        (camel_imap_store_summary_add_from_full): map the namespace if
        present.
        (camel_imap_store_summary_path_to_full): If namespace exists,
        unmap it.

21 years agoCanonicalise the source_uri to not have a path. Fixes bug #32268.
Jeffrey Stedfast [Tue, 22 Oct 2002 18:17:06 +0000 (18:17 +0000)]
Canonicalise the source_uri to not have a path. Fixes bug #32268.

2002-10-18  Jeffrey Stedfast  <fejj@ximian.com>

* camel-filter-driver.c (camel_filter_driver_filter_folder):
Canonicalise the source_uri to not have a path. Fixes bug #32268.

2002-10-17  Jeffrey Stedfast  <fejj@ximian.com>

Possible fix for bug #32270

* providers/pop3/camel-pop3-store.c (try_sasl): If we get an I/O
error, we should not be setting the CANT_AUTH exception but should
instead be setting the SYSTEM exception. Also check for EINTR
which signifies a USER_CANCEL exception.
(pop3_try_authenticate): If the auth mechanism isn't supported,
don't set the CANT_AUTH exception since then we will loop and try
again with the same data which will just cause an infinite loop.
(pop3_connect): Simplified a bit.

21 years ago#include "camel-stream-fs.h" for writing out the certs to disk
Jeffrey Stedfast [Fri, 18 Oct 2002 17:59:59 +0000 (17:59 +0000)]
#include "camel-stream-fs.h" for writing out the certs to disk

21 years agoDo the filtering ourselves. This is so a problem like a missing uid (which
Not Zed [Fri, 18 Oct 2002 03:32:42 +0000 (03:32 +0000)]
Do the filtering ourselves. This is so a problem like a missing uid (which

2002-10-03  Not Zed  <NotZed@Ximian.com>

        * camel-folder.c
        (filter_filter): Do the filtering ourselves.  This is so a problem
        like a missing uid (which can happen legitemitely) doesn't
        prematurely abort filtering.  Stop on all other errors.  See
        #31667.

21 years agoIf ~/.camel_certs doesn't exist, create it.
Jeffrey Stedfast [Fri, 18 Oct 2002 03:03:13 +0000 (03:03 +0000)]
If ~/.camel_certs doesn't exist, create it.

2002-10-17  Jeffrey Stedfast  <fejj@ximian.com>

* camel-tcp-stream-ssl.c (camel_certdb_nss_cert_set): If
~/.camel_certs doesn't exist, create it.

21 years agohelper, build fingerprint. (camel_certdb_nss_cert_get): Helper for nss
Not Zed [Thu, 17 Oct 2002 03:56:13 +0000 (03:56 +0000)]
helper, build fingerprint. (camel_certdb_nss_cert_get): Helper for nss

2002-10-15  Not Zed  <NotZed@Ximian.com>

        * camel-tcp-stream-ssl.c (cert_fingerprint): helper, build
        fingerprint.
        (camel_certdb_nss_cert_get): Helper for nss certs.  Lookup cert.
        As well as fingerprint, the whole raw cert is checked for
        validity.
        (camel_certdb_nss_cert_add): Add an nss cert to a certdb, also
        saves the cert by fingerprint in ~/.camel_certs/.
        (ssl_bad_cert): Changed to use above functions to simplify logic.
        (ssl_bad_cert): Also added non-compiled code which mimics what
        mozilla does, but it doesn't work right :-/
        (camel_certdb_nss_cert_set): Save the raw cert associated with a
        cert.

        * camel-certdb.c (certdb_cert_free): Free the raw cert data if
        set.

2002-10-14  Not Zed  <NotZed@Ximian.com>

        * camel-file-utils.c (camel_file_util_encode_string): Encode a
        length of 0 as 1, not 0, to match the decode code.

21 years agoNo longer takes a path argument. (camel_gpg_context_fianlise): No need to
Jeffrey Stedfast [Thu, 17 Oct 2002 03:01:36 +0000 (03:01 +0000)]
No longer takes a path argument. (camel_gpg_context_fianlise): No need to

2002-10-16  Jeffrey Stedfast  <fejj@ximian.com>

* camel-gpg-context.c (camel_gpg_context_new): No longer takes a
path argument.
(camel_gpg_context_fianlise): No need to free ctx->path.
(gpg_ctx_new): No longer takes a path argument either.
(gpg_ctx_free): No need to free ctx->path, it's no longer used.
(gpg_ctx_op_start): Don't stat the path anymore and change the
first arg to execvp to "gpg" so that we use the shell's
environment to find gpg.
(gpg_sign): Updated.
(gpg_verify): Updated.
(gpg_encrypt): Updated.
(gpg_decrypt): Updated.
(gpg_ctx_get_argv): Removed some debug printfs.

21 years agoIf the hash id is NULL, return CAMEL_CIPHER_HASH_DEFAULT. Fixes bug
Jeffrey Stedfast [Tue, 15 Oct 2002 20:09:18 +0000 (20:09 +0000)]
If the hash id is NULL, return CAMEL_CIPHER_HASH_DEFAULT. Fixes bug

2002-10-15  Jeffrey Stedfast  <fejj@ximian.com>

* camel-gpg-context.c (gpg_id_to_hash): If the hash id is NULL,
return CAMEL_CIPHER_HASH_DEFAULT. Fixes bug #32229.

21 years agoIf the response from the IMAP server is "No", don't set the
Jeffrey Stedfast [Wed, 9 Oct 2002 17:29:34 +0000 (17:29 +0000)]
If the response from the IMAP server is "No", don't set the

2002-10-08  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-command.c (imap_read_response): If the
response from the IMAP server is "No", don't set the
SERVICE_UNAVAILABLE exception, this makes error reporting in the
UI for deleting IMAP folders that cannot be deleted inaccurate
(ie, it reports "Cannot delete in offline mode" which is not the
problem).

21 years agoFixes bug #31752
Jeffrey Stedfast [Mon, 7 Oct 2002 18:13:53 +0000 (18:13 +0000)]
Fixes bug #31752

2002-10-07  Jeffrey Stedfast  <fejj@ximian.com>

Fixes bug #31752

* providers/smtp/camel-smtp-transport.c (connect_to_server): Don't
forget to send another EHLO command to the server once we toggle
into STARTTLS mode.
(smtp_helo): Reset any flags set using the EHLO response and also
any authtypes.

21 years agoFix all mailing list regex patterns to allow any number of spaces *or*
Jeffrey Stedfast [Mon, 7 Oct 2002 18:10:24 +0000 (18:10 +0000)]
Fix all mailing list regex patterns to allow any number of spaces *or*

2002-10-06  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-utils.c: Fix all mailing list regex patterns to allow
any number of spaces *or* tabs as pre-padding for the header
values.

21 years agoUse the content-object's rawtext flag to decide if it needs to be filtered
Jeffrey Stedfast [Fri, 4 Oct 2002 17:24:45 +0000 (17:24 +0000)]
Use the content-object's rawtext flag to decide if it needs to be filtered

2002-10-03  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-part.c (write_to_stream): Use the content-object's
rawtext flag to decide if it needs to be filtered through the
charset filter instead of using the mime part's rawtext flag since
this will never be set. Partial fix for bug #31655.

21 years agoDont get the filter driver inside the change_lock. Its not necessary, and
Not Zed [Fri, 4 Oct 2002 03:00:23 +0000 (03:00 +0000)]
Dont get the filter driver inside the change_lock. Its not necessary, and

2002-10-03  Not Zed  <NotZed@Ximian.com>

        * camel-folder.c (folder_changed): Dont get the filter driver
        inside the change_lock.  Its not necessary, and can cause deadlock
        with the way the mailer gets the filter driver via g_mainloop.
        Should fix #31572.

21 years agoMap us-ascii to windows-1252 also.
Jeffrey Stedfast [Thu, 3 Oct 2002 16:53:20 +0000 (16:53 +0000)]
Map us-ascii to windows-1252 also.

2002-10-02  Jeffrey Stedfast  <fejj@ximian.com>

* camel-charset-map.c (camel_charset_iso_to_windows): Map us-ascii
to windows-1252 also.

21 years ago Add missing ;.
Michael Zucci [Thu, 3 Oct 2002 01:54:52 +0000 (01:54 +0000)]
Add missing ;.

21 years ago/home/notzed/gnome/head/evolution/camel
Not Zed [Thu, 3 Oct 2002 00:15:23 +0000 (00:15 +0000)]
/home/notzed/gnome/head/evolution/camel
2002-10-02  Not Zed  <NotZed@Ximian.com>

        * providers/imap/camel-imap-folder.c (get_matching): Set *set to
        NULL if we dont get any matches.
        (imap_sync_online): If we get no matches, skip any work, also
        reorder some code to make it easier to skip.  See #31031.

        * providers/imap/camel-imap-store.c
        (imap_check_folder_still_extant): Default to "TRUE", if the list
        command failed, it probably means a server problem, assume the
        worst.  This makes imap_refresh_info not clear the exception and
        crash.  Fixes crash of #31000.

2002-10-01  Not Zed  <NotZed@Ximian.com>

        * providers/imap/camel-imap-folder.c (imap_refresh_info): Make
        sure we pass the exception to imap_folder_selected(), otherwise
        failures can be lost.  See bug #31000.

2002-10-01  Not Zed  <NotZed@Ximian.com>

        * camel-folder.c (thaw): Add an assertion that the frozen count>0.
        (freeze): Same for >= 0.

        * camel-vee-folder.c (camel_vee_folder_remove_folder): Use the
        unmatched freeze_count when thawing folders removed from
        unmatched, rather than the folder's freeze_count.  Might be
        related to #27391.

21 years agoUse strtol when decoding the timezone (since it can be negative) and don't
Jeffrey Stedfast [Tue, 1 Oct 2002 18:04:46 +0000 (18:04 +0000)]
Use strtol when decoding the timezone (since it can be negative) and don't

2002-10-01  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-folder.c (decode_internaldate): Use
strtol when decoding the timezone (since it can be negative) and
don't forget to increment inptr to the start of the time (ie,
don't leave inptr pointing to the year when decoding the
hour:min:sec).

21 years agoFixes bug #31456.
Jeffrey Stedfast [Mon, 30 Sep 2002 22:57:42 +0000 (22:57 +0000)]
Fixes bug #31456.

2002-09-30  Jeffrey Stedfast  <fejj@ximian.com>

Fixes bug #31456.

* providers/imap/camel-imap-store.c (imap_connect_online): Don't
LSUB "" "*", instead get both an LSUB containing the subfolders of
the namespace and an LSUB of INBOX (assuming namespace was
non-empty). This fix really has nothing to do with bug #31456 but
is what should have been done in the first place.
(parse_list_response_as_folder_info): Simplify a tad and strip
extra leading /'s from fi->path.
(imap_build_folder_info): Strip extra leading /'s from fi->path.

* camel-store.c (camel_folder_info_build): Don't strip the
namespace from the fi->full_name when hashing or creating fake
parent folder-infos. Fixes a bug I found while trying to reproduce
bug #31456.
(camel_folder_info_build_path): Strip off extra leading dir_sep
chars from the path.

21 years agoDon't strip the namespace from the fi->full_name when hasing or creating
Jeffrey Stedfast [Mon, 30 Sep 2002 20:45:42 +0000 (20:45 +0000)]
Don't strip the namespace from the fi->full_name when hasing or creating

2002-09-30  Jeffrey Stedfast  <fejj@ximian.com>

* camel-store.c (camel_folder_info_build): Don't strip the
namespace from the fi->full_name when hasing or creating fake
parent folders. Fixes a bug I found while trying to reproduce bug
#31456.

21 years agoRemove debug content_info_dump, could cause a crash, and not really needed
Not Zed [Mon, 30 Sep 2002 05:06:51 +0000 (05:06 +0000)]
Remove debug content_info_dump, could cause a crash, and not really needed

2002-09-30  Not Zed  <NotZed@Ximian.com>

* providers/imap/camel-imap-folder.c (imap_get_message): Remove
debug content_info_dump, could cause a crash, and not really
needed anymore.

* camel-folder-summary.c (camel_content_info_dump): Check ci->type
!= NULL before dereferencing it.  Should fix crash #31331.

21 years agoNew function to decode the INTERNALDATE response from an IMAP server so we
Jeffrey Stedfast [Fri, 27 Sep 2002 20:20:08 +0000 (20:20 +0000)]
New function to decode the INTERNALDATE response from an IMAP server so we

2002-09-27  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-folder.c (decode_internaldate): New
function to decode the INTERNALDATE response from an IMAP server
so we don't have to use my broken-date-parser routines.

2002-09-27  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-store.c (connect_to_server):
NULL-check the streams before unreffing them in the case of a
failure during ssl negotiations.

* camel-tcp-stream-ssl.c (camel_tcp_stream_ssl_enable_ssl): Check
SSL_ResetHandshake() for errors. Also force a handshake after
we've reset the handshake state on the socket.

21 years agoUse the summary's last uid as the one to fetch from, ignoring the cache.
Not Zed [Fri, 27 Sep 2002 05:34:05 +0000 (05:34 +0000)]
Use the summary's last uid as the one to fetch from, ignoring the cache.

2002-09-27  Not Zed  <NotZed@Ximian.com>

        * providers/imap/camel-imap-folder.c (imap_update_summary): Use
        the summary's last uid as the one to fetch from, ignoring the
        cache.  Use strotul instead of atoi as well.

        * providers/imap/camel-imap-store.c (get_folder_counts): If we
        have the folder open, and the unread count has changed, refresh
        it.  Should fix #30399 enough.  Also in non-check-all mode, if we
        have the folder open, use it anyway.

21 years agoTreat spool as a local folder, so the ref checks work right.
Not Zed [Thu, 26 Sep 2002 05:56:12 +0000 (05:56 +0000)]
Treat spool as a local folder, so the ref checks work right.

2002-09-26  Not Zed  <NotZed@Ximian.com>

* tests/folder/test2.c (main): Treat spool as a local folder, so
the ref checks work right.

* providers/local/camel-spool-store.c
(get_folder): Use creat() instead of open() to create file.

21 years agoImplement FOLDER_CREATE flag. (scan_dir): Dont free name on exception, its
Not Zed [Thu, 26 Sep 2002 05:34:10 +0000 (05:34 +0000)]
Implement FOLDER_CREATE flag. (scan_dir): Dont free name on exception, its

2002-09-26  Not Zed  <NotZed@Ximian.com>

        * providers/local/camel-spool-store.c (get_folder): Implement
        FOLDER_CREATE flag.
        (scan_dir): Dont free name on exception, its alloca'd.
        (scan_dir): If we start scanning from a file, just add that
        directly.
        (scan_dir): Allow empty files to also show up in folder list, as
        well as files starting with "From ".

        * providers/local/camel-spool-folder.c (camel_spool_folder_new):
        Check folder != NULL before writing to it.

        * providers/local/camel-local-store.c (create_folder): Handle a
        parent of NULL for creating top-level dirs.  Part of #31186.

21 years agoStore the folder flags in the store summary. (get_one_folder_offline): Set
Not Zed [Thu, 26 Sep 2002 02:39:16 +0000 (02:39 +0000)]
Store the folder flags in the store summary. (get_one_folder_offline): Set

2002-09-26  Not Zed  <NotZed@Ximian.com>

        * providers/imap/camel-imap-store.c
        (parse_list_response_as_folder_info): Store the folder flags in
        the store summary.
        (get_one_folder_offline): Set the noselect url parameter if this
        is a noselect folder, from the stored summary flags.  #30877.

21 years agoHandle EILSEQ by eating bytes in the input buffer until conversion is
Jeffrey Stedfast [Wed, 25 Sep 2002 23:33:45 +0000 (23:33 +0000)]
Handle EILSEQ by eating bytes in the input buffer until conversion is

2002-09-23  Jeffrey Stedfast  <fejj@ximian.com>

* camel-mime-filter-charset.c (complete): Handle EILSEQ by eating
bytes in the input buffer until conversion is successful. The old
behaviour aborted when it got EILSEQ and just dumped the raw data.
(filter): Same. Fixes bug #30873.

21 years agoAdded a test suite for camel-mime-filter-charset and added a few test cases for it...
Jeffrey Stedfast [Wed, 25 Sep 2002 23:25:05 +0000 (23:25 +0000)]
Added a test suite for camel-mime-filter-charset and added a few test cases for it. input charset files should be in the form "charset-%s.%d.in" where %s is the charset name that the file is in and %d is just some number as in a sequence id. Mostly just so we can have multiple test files per charset

21 years agoChanged the Mailing-List rule to get the complete domain (* in wrong
Not Zed [Tue, 24 Sep 2002 05:48:14 +0000 (05:48 +0000)]
Changed the Mailing-List rule to get the complete domain (* in wrong

2002-09-24  Not Zed  <NotZed@Ximian.com>

* camel-mime-utils.c (mail_list_magic[]): Changed the Mailing-List
rule to get the complete domain (* in wrong spot).  #31087.

21 years agoIf we have no data written to a key, dont add it, or its partition header.
Not Zed [Tue, 24 Sep 2002 01:16:12 +0000 (01:16 +0000)]
If we have no data written to a key, dont add it, or its partition header.

2002-09-24  Not Zed  <NotZed@Ximian.com>

        * camel-text-index.c (text_index_compress_nosync): If we have no
        data written to a key, dont add it, or its partition header.

2002-09-23  Not Zed  <NotZed@Ximian.com>

        * camel-block-file.c (sync_nolock): Mark root block dirty if we're
        going to sync it.
        (camel_key_file_finalise): de-count the active list if we close
        it.

        * camel-text-index.c (text_index_delete): Implement.
        (text_index_compress_nosync): Use index_delete when we're finished
        with the old one, so it is properly deactivated.

        * camel-index.c (camel_index_delete): Remove api call.  Mark index
        deleted in new state variable.
        (camel_index_*): Wrap all calls in check for deleted state.

21 years agoIf the original message is deleted, reset the deleted flag when we're
Jeffrey Stedfast [Mon, 23 Sep 2002 20:48:50 +0000 (20:48 +0000)]
If the original message is deleted, reset the deleted flag when we're

2002-09-23  Jeffrey Stedfast  <fejj@ximian.com>

* camel-folder.c (transfer_message_to): If the original message is
deleted, reset the deleted flag when we're done. Fixes bug #30876.

21 years agoDecode the INTERNALDATE if we've got one. (imap_update_summary): Instead
Jeffrey Stedfast [Mon, 23 Sep 2002 20:03:17 +0000 (20:03 +0000)]
Decode the INTERNALDATE if we've got one. (imap_update_summary): Instead

2002-09-23  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-folder.c (add_message_from_data):
Decode the INTERNALDATE if we've got one.
(imap_update_summary): Instead of requesting a list of specific
headers, request HEADER.FIELDS.NOT (RECEIVED) to reduce bandwidth
usage even more.
(parse_fetch_response): Change slightly to allow HEADER.FIELDS or
HEADER.FIELDS.NOT so that we can make changes in
imap_update_summary and not need to keep changing this function to
match. Also parse an INTERNALDATE response.

21 years agofix non-ANSI switch statement.
Dan Winship [Sun, 22 Sep 2002 23:49:06 +0000 (23:49 +0000)]
fix non-ANSI switch statement.

        * camel-mime-parser.c (folder_scan_drop_step): fix non-ANSI switch
        statement.

        * camel-service.c (service_getv): Likewise.

        * providers/imap/camel-imap-store.c (imap_getv): Likewise.

        * providers/pop3/camel-pop3-folder.c (cmd_builduid): Likewise.

21 years agoNew regression test for word splitting/search input parsing code.
Not Zed [Fri, 20 Sep 2002 05:30:27 +0000 (05:30 +0000)]
New regression test for word splitting/search input parsing code.

2002-09-20  Not Zed  <NotZed@Ximian.com>

        * tests/misc/split.c: New regression test for word
        splitting/search input parsing code.

        * tests/folder/test9.c (main): Fix for filter_driver api change.

        * camel-search-private.c (camel_search_words_split): Handle "'s
        and \'s to escape characters.  For fat, lazy, slobs who dont like
        anything changing.

21 years agoTake new session arg. Update callers. (symbols[]): changed get-source to
Not Zed [Thu, 19 Sep 2002 13:26:38 +0000 (13:26 +0000)]
Take new session arg. Update callers. (symbols[]): changed get-source to

2002-09-19  Not Zed  <NotZed@Ximian.com>

        * camel-filter-search.c (camel_filter_search_match): Take new
        session arg.  Update callers.
        (symbols[]): changed get-source to header-source
        (header_source): Chagned from get_source.  Now a boolean, returns
        true if source matches one of the arguments.  Uses the provider
        url comparison directly for accurate checking.  Makes 'filter on
        source' work.

        * camel-filter-driver.c (camel_filter_driver_new): Take new arg,
        session.
        (camel_filter_driver_finalise): Free session.

21 years agoDon't increment the response pointer when deciding what type of header
Jeffrey Stedfast [Thu, 19 Sep 2002 06:17:16 +0000 (06:17 +0000)]
Don't increment the response pointer when deciding what type of header

2002-09-19  Jeffrey Stedfast  <fejj@ximian.com>

* providers/imap/camel-imap-folder.c (parse_fetch_response): Don't
increment the response pointer when deciding what type of header
response we got, this screws up the string that we strdup into the
part_spec string later. Also, instead of using the entire blob of
HEADER.FIELDS that we get in the response, shorten it to just
HEADER.FIELDS to use as the part_spec key.

21 years agofixed a merge conflict
Jeffrey Stedfast [Thu, 19 Sep 2002 02:38:20 +0000 (02:38 +0000)]
fixed a merge conflict