[evolution-rss] don't crash on failed plugin initialization
- From: Lucian Langa <lucilanga src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-rss] don't crash on failed plugin initialization
- Date: Fri, 20 Mar 2015 10:06:58 +0000 (UTC)
commit de5ddb1df6d9c22bf6918cd81a8783b8228c67a2
Author: Lucian Langa <lucilanga gnome org>
Date: Fri Mar 20 10:58:44 2015 +0100
don't crash on failed plugin initialization
src/e-mail-formatter-evolution-rss.c | 4 ++++
src/rss.c | 2 ++
2 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/e-mail-formatter-evolution-rss.c b/src/e-mail-formatter-evolution-rss.c
index b3eb77a..09ba3cc 100644
--- a/src/e-mail-formatter-evolution-rss.c
+++ b/src/e-mail-formatter-evolution-rss.c
@@ -37,6 +37,7 @@
#include "e-mail-part-rss.h"
extern gchar *commstream;
+extern int rss_init;
typedef EMailFormatterExtension EMailFormatterRSS;
typedef EMailFormatterExtensionClass EMailFormatterRSSClass;
@@ -128,6 +129,9 @@ emfe_evolution_rss_format (EMailFormatterExtension *extension,
goto fail;
}
+ if (!rss_init)
+ goto fail;
+
h = g_strdup(e_web_view_get_html (E_WEB_VIEW (rss_get_display())));
website = (gchar *)camel_medium_get_header (
diff --git a/src/rss.c b/src/rss.c
index 69d49a5..2ae242e 100644
--- a/src/rss.c
+++ b/src/rss.c
@@ -22,6 +22,7 @@
#endif
int rss_verbose_debug = 0;
+int rss_init = 0;
#define _GNU_SOURCE
#include <string.h>
@@ -3398,6 +3399,7 @@ void org_gnome_cooly_rss_startup(void *ep, void *t)
custom_feed_timeout();
rss_init_images();
+ rss_init = 1;
}
/* check if rss folders exists and create'em otherwise */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]