diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2013-09-02 23:33:48 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2013-09-02 23:57:28 +0800 |
commit | 19e784a4b2655db5cf414c7ce43662a9adb9d0c6 (patch) | |
tree | c4c8b67bc8e75714b6104614fa0ec1b97febe29f /libempathy-gtk | |
parent | c7103f75e10d3c8efd65f6e60bc446a198cbb080 (diff) | |
download | gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar.gz gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar.bz2 gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar.lz gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar.xz gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.tar.zst gsoc2013-empathy-19e784a4b2655db5cf414c7ce43662a9adb9d0c6.zip |
theme-adium: deal with g_resources_lookup_data() failing
Only empathy-chat registers the gresources so when executing this code from
the empathy process (theme preview in the preferences dialog) we don't find
the resource. That's fine as this JS code is only used for the infinite
callback but best to not warning.
https://bugzilla.gnome.org/show_bug.cgi?id=707291
Diffstat (limited to 'libempathy-gtk')
-rw-r--r-- | libempathy-gtk/empathy-theme-adium.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-theme-adium.c b/libempathy-gtk/empathy-theme-adium.c index 0cf74e396..ba359ceb1 100644 --- a/libempathy-gtk/empathy-theme-adium.c +++ b/libempathy-gtk/empathy-theme-adium.c @@ -732,6 +732,9 @@ theme_adium_add_html (EmpathyThemeAdium *self, bytes = g_resources_lookup_data ("/org/gnome/Empathy/Chat/empathy-chat.js", G_RESOURCE_LOOKUP_FLAGS_NONE, NULL); + if (bytes == NULL) + return; + js = (const gchar *) g_bytes_get_data (bytes, NULL); g_string_prepend (string, js); g_bytes_unref (bytes); |