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

svn path=/trunk/; revision=19002
This commit is contained in:
Jeffrey Stedfast
2002-12-04 16:17:02 +00:00
committed by Jeffrey Stedfast
parent 200071108f
commit d4b7008db3
3 changed files with 14 additions and 5 deletions

View File

@ -1,3 +1,9 @@
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
2002-12-03 Jeffrey Stedfast <fejj@ximian.com> 2002-12-03 Jeffrey Stedfast <fejj@ximian.com>
* broken-date-parser.c (get_tzone): Fixed to not get false * broken-date-parser.c (get_tzone): Fixed to not get false

View File

@ -318,9 +318,14 @@ camel_imap_store_summary_add_from_full(CamelImapStoreSummary *s, const char *ful
} else { } else {
if (full_name[len] == ns->sep) if (full_name[len] == ns->sep)
len++; len++;
prefix = camel_imap_store_summary_full_to_path(s, full_name+len, ns->sep); prefix = camel_imap_store_summary_full_to_path(s, full_name+len, ns->sep);
pathu8 = g_strdup_printf("%s/%s", ns->path, prefix); if (*ns->path) {
g_free(prefix); pathu8 = g_strdup_printf ("%s/%s", ns->path, prefix);
g_free (prefix);
} else {
pathu8 = prefix;
}
} }
d(printf(" (pathu8 = '%s')", pathu8)); d(printf(" (pathu8 = '%s')", pathu8));
} else { } else {
@ -343,7 +348,6 @@ camel_imap_store_summary_add_from_full(CamelImapStoreSummary *s, const char *ful
char * char *
camel_imap_store_summary_full_from_path(CamelImapStoreSummary *s, const char *path) camel_imap_store_summary_full_from_path(CamelImapStoreSummary *s, const char *path)
{ {
CamelImapStoreInfo *si;
CamelImapStoreNamespace *ns; CamelImapStoreNamespace *ns;
char *name = NULL; char *name = NULL;
@ -362,7 +366,6 @@ CamelImapStoreNamespace *camel_imap_store_summary_namespace_new(CamelImapStoreSu
CamelImapStoreNamespace *ns; CamelImapStoreNamespace *ns;
char *p; char *p;
int len; int len;
GString *tmp;
ns = g_malloc0(sizeof(*ns)); ns = g_malloc0(sizeof(*ns));
ns->full_name = g_strdup(full_name); ns->full_name = g_strdup(full_name);

View File

@ -2140,7 +2140,7 @@ get_folders_online (CamelImapStore *imap_store, const char *pattern,
g_hash_table_destroy(present); g_hash_table_destroy(present);
} }
#if 1 #if 0
static void static void
dumpfi(CamelFolderInfo *fi) dumpfi(CamelFolderInfo *fi)
{ {