Re: Reading the suspended flag in maildir folders
- From: Sergio Villar Senin <svillar igalia com>
- To: tinymail-devel-list gnome org
- Subject: Re: Reading the suspended flag in maildir folders
- Date: Wed, 30 Jan 2008 17:52:00 +0100
Sergio Villar Senin wrote:
> Hi,
>
> I'm experiencing some issues after marking a message as suspended in a
> maildir folder. The problem is that I'm not able to get it anymore. The
> problem is that the maildir_get_message tries to open a file whose
> filename that does not exists. The reason is that the name of the file
> name stored in the disk is something like blablablabla.machine!2,AON and
> the get_message function tries to retrieve blablablabla.machine!2,AN.
After talking with Philip on IRC we agreed on that the message should be
read no matter what the flags are. So I'm attaching a patch that fixes
the message reading in mailbox folders.
Br
Index: libtinymail-camel/camel-lite/camel/providers/local/camel-maildir-summary.c
===================================================================
--- libtinymail-camel/camel-lite/camel/providers/local/camel-maildir-summary.c (revision 3328)
+++ libtinymail-camel/camel-lite/camel/providers/local/camel-maildir-summary.c (working copy)
@@ -864,6 +864,13 @@
if (dir) {
while ( (d = readdir(dir)) ) {
char *nname = g_strdup_printf ("%s/%s", cur, d->d_name);
+ char *ptr = strstr (nname, "!");
+
+ if (!ptr)
+ strstr (nname, ":");
+ if (ptr)
+ len = (ptr - nname);
+
if (!g_ascii_strncasecmp (nname, name, len)) {
g_free (name);
name = nname;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]