[nautilus/gnome-3-10] NautilusFile: fix crash in modify_link_hash_table
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/gnome-3-10] NautilusFile: fix crash in modify_link_hash_table
- Date: Thu, 6 Feb 2014 17:38:01 +0000 (UTC)
commit 692b8824bdd8250253ef64861057e15040216fb0
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Wed Nov 6 21:53:45 2013 -0600
NautilusFile: fix crash in modify_link_hash_table
We crash in g_hash_table_lookup_extended if the file's symlink_name is
set but the file is not a symlink, since the hash function (g_str_hash)
does not allow NULL values but target_uri is NULL.
https://bugzilla.gnome.org/show_bug.cgi?id=711583
libnautilus-private/nautilus-file.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/libnautilus-private/nautilus-file.c b/libnautilus-private/nautilus-file.c
index 6fbc6d8..4287fc8 100644
--- a/libnautilus-private/nautilus-file.c
+++ b/libnautilus-private/nautilus-file.c
@@ -553,7 +553,7 @@ modify_link_hash_table (NautilusFile *file,
GList **list_ptr;
/* Check if there is a symlink name. If none, we are OK. */
- if (file->details->symlink_name == NULL) {
+ if (file->details->symlink_name == NULL || !nautilus_file_is_symbolic_link (file)) {
return;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]