diff options
author | Rodrigo Moya <rodrigo@ximian.com> | 2002-09-20 20:53:26 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@src.gnome.org> | 2002-09-20 20:53:26 +0800 |
commit | a1b984a5fb42b96ea7f99a14a427bd1b3e19b606 (patch) | |
tree | ea188ba3784b60366bc522175fc791dbeadb6d0b | |
parent | aa250a4b9654847ad6edfd4ac34ac28c5f6458d4 (diff) | |
download | gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar.gz gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar.bz2 gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar.lz gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar.xz gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.tar.zst gsoc2013-evolution-a1b984a5fb42b96ea7f99a14a427bd1b3e19b606.zip |
remove the query from the cache if it failed. (start_cached_query_cb):
2002-09-20 Rodrigo Moya <rodrigo@ximian.com>
* pcs/query.c (parse_sexp): remove the query from the cache if it
failed.
(start_cached_query_cb): notify of errors in the query.
svn path=/trunk/; revision=18133
-rw-r--r-- | calendar/ChangeLog | 6 | ||||
-rw-r--r-- | calendar/pcs/query.c | 17 |
2 files changed, 23 insertions, 0 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index b39e4aec63..91eea57af8 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,9 @@ +2002-09-20 Rodrigo Moya <rodrigo@ximian.com> + + * pcs/query.c (parse_sexp): remove the query from the cache if it + failed. + (start_cached_query_cb): notify of errors in the query. + 2002-09-19 Rodrigo Moya <rodrigo@ximian.com> * pcs/query.c: added a list of EComponentListener's to control the diff --git a/calendar/pcs/query.c b/calendar/pcs/query.c index 73d40324b2..15b5c41ec2 100644 --- a/calendar/pcs/query.c +++ b/calendar/pcs/query.c @@ -1148,6 +1148,10 @@ parse_sexp (Query *query) e_sexp_unref (priv->esexp); priv->esexp = NULL; + /* remove the query from the list of cached queries */ + cached_queries = g_list_remove (cached_queries, query); + bonobo_object_unref (BONOBO_OBJECT (query)); + return FALSE; } @@ -1462,6 +1466,19 @@ start_cached_query_cb (gpointer data) } else if (priv->state == QUERY_IN_PROGRESS) { /* if it's in progress, we just wait */ return TRUE; + } else if (priv->state == QUERY_PARSE_ERROR) { + CORBA_exception_init (&ev); + GNOME_Evolution_Calendar_QueryListener_notifyQueryDone ( + info->ql, + GNOME_Evolution_Calendar_QueryListener_PARSE_ERROR, + _("Parse error"), + &ev); + + if (BONOBO_EX (&ev)) + g_message ("start_cached_query_cb(): Could not notify the listener of " + "a parse error"); + + CORBA_exception_free (&ev); } /* if the query is done, then we just notify the listener */ |