summaryrefslogtreecommitdiffstats
path: root/main/nautilus/003-filename-null.patch
blob: 56a32d9f44d41e431dcfae3a9bbcaf932bfdb029 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
From 1df5a0ceb27f2cb4ef201344a558a3e961094cc4 Mon Sep 17 00:00:00 2001
From: Rodrigo Moya <rodrigo@gnome-db.org>
Date: Thu, 24 Feb 2011 16:47:29 +0000
Subject: Guard against filename being NULL on nautilus_icon_info_lookup

---
diff --git a/libnautilus-private/nautilus-icon-info.c b/libnautilus-private/nautilus-icon-info.c
index f39ad42..97e88cb 100644
--- a/libnautilus-private/nautilus-icon-info.c
+++ b/libnautilus-private/nautilus-icon-info.c
@@ -392,6 +392,9 @@ nautilus_icon_info_lookup (GIcon *icon,
 		}
 
 		filename = gtk_icon_info_get_filename (gtkicon_info);
+		if (filename == NULL) {
+			return nautilus_icon_info_new_for_pixbuf (NULL);
+		}
 
 		lookup_key.filename = (char *)filename;
 		lookup_key.size = size;
--
cgit v0.9