[gupnp-tools] universal-cp: If icon fetch fails, use default
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gupnp-tools] universal-cp: If icon fetch fails, use default
- Date: Sat, 8 Jan 2022 20:36:57 +0000 (UTC)
commit 40fd188752d5dc25cd44a634e78c7041446a0140
Author: Jens Georg <mail jensge org>
Date: Sat Jan 8 21:36:13 2022 +0100
universal-cp: If icon fetch fails, use default
Fixes #23
src/universal-cp/device-treeview.c | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/src/universal-cp/device-treeview.c b/src/universal-cp/device-treeview.c
index bb904a6..df3a649 100644
--- a/src/universal-cp/device-treeview.c
+++ b/src/universal-cp/device-treeview.c
@@ -388,6 +388,12 @@ on_device_icon_available (GUPnPDeviceInfo *info,
GtkTreeIter device_iter;
const char *udn;
+ // There was no icon or there was an error getting that
+ // icon. Just keep the default then
+ if (icon == NULL) {
+ return;
+ }
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (treeview));
g_assert (model != NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]