aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2001-10-17 03:03:16 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-10-17 03:03:16 +0800
commite1d0f3dc45692a04dbd93c7ef82c24af74e05f25 (patch)
tree5e042b926fea9c5a07302c929ce2562b01fff5e3
parentc8434d2f7cb0894afbea774943cfae7b20a8b943 (diff)
downloadgsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar.gz
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar.bz2
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar.lz
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar.xz
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.tar.zst
gsoc2013-evolution-e1d0f3dc45692a04dbd93c7ef82c24af74e05f25.zip
Only perform the operation on the folder if the folder has summary
2001-10-16 Jeffrey Stedfast <fejj@ximian.com> * camel-filter-driver.c (do_flag): Only perform the operation on the folder if the folder has summary capability, else just poke the info directly. Fixes the "Filters don't work" bug. (do_score): Same. (do_colour): And here too. svn path=/trunk/; revision=13697
-rw-r--r--camel/ChangeLog8
-rw-r--r--camel/camel-filter-driver.c6
2 files changed, 11 insertions, 3 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog
index d8fd6eaaeb..0cbe6a4fdb 100644
--- a/camel/ChangeLog
+++ b/camel/ChangeLog
@@ -1,3 +1,11 @@
+2001-10-16 Jeffrey Stedfast <fejj@ximian.com>
+
+ * camel-filter-driver.c (do_flag): Only perform the operation on
+ the folder if the folder has summary capability, else just poke
+ the info directly. Fixes the "Filters don't work" bug.
+ (do_score): Same.
+ (do_colour): And here too.
+
2001-10-15 Jeffrey Stedfast <fejj@ximian.com>
* camel-stream-fs.c (stream_read): Save the errno before calling
diff --git a/camel/camel-filter-driver.c b/camel/camel-filter-driver.c
index d90798eb76..8d8822b72d 100644
--- a/camel/camel-filter-driver.c
+++ b/camel/camel-filter-driver.c
@@ -456,7 +456,7 @@ do_colour (struct _ESExp *f, int argc, struct _ESExpResult **argv, CamelFilterDr
d(fprintf (stderr, "setting colour tag\n"));
if (argc > 0 && argv[0]->type == ESEXP_RES_STRING) {
- if (p->source && p->uid)
+ if (p->source && p->uid && camel_folder_has_summary_capability (p->source))
camel_folder_set_message_user_tag(p->source, p->uid, "colour", argv[0]->value.string);
else
camel_tag_set (&p->info->user_tags, "colour", argv[0]->value.string);
@@ -476,7 +476,7 @@ do_score (struct _ESExp *f, int argc, struct _ESExpResult **argv, CamelFilterDri
char *value;
value = g_strdup_printf ("%d", argv[0]->value.number);
- if (p->source && p->uid)
+ if (p->source && p->uid && camel_folder_has_summary_capability (p->source))
camel_folder_set_message_user_tag(p->source, p->uid, "score", value);
else
camel_tag_set (&p->info->user_tags, "score", value);
@@ -494,7 +494,7 @@ do_flag (struct _ESExp *f, int argc, struct _ESExpResult **argv, CamelFilterDriv
d(fprintf (stderr, "setting flag\n"));
if (argc == 1 && argv[0]->type == ESEXP_RES_STRING) {
- if (p->source && p->uid)
+ if (p->source && p->uid && camel_folder_has_summary_capability (p->source))
camel_folder_set_message_flags(p->source, p->uid, camel_system_flag(argv[0]->value.string), ~0);
else
p->info->flags |= camel_system_flag (argv[0]->value.string)|CAMEL_MESSAGE_FOLDER_FLAGGED;