summaryrefslogtreecommitdiff
path: root/src/file-manager/fm-icon-view.c
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2013-09-19 16:40:14 +0200
committerStefano Karapetsas <[email protected]>2013-09-22 20:35:09 +0200
commit73cc7e98f61b2d5f327f26a2e6f4e5004347bf01 (patch)
tree8814f35a3fdd57d8d2a52dfdc0986b8ee4c8b6a7 /src/file-manager/fm-icon-view.c
parent38e0a2bd39c65001100f403dd2bd4162ffd824de (diff)
downloadcaja-73cc7e98f61b2d5f327f26a2e6f4e5004347bf01.tar.bz2
caja-73cc7e98f61b2d5f327f26a2e6f4e5004347bf01.tar.xz
Possible fix for crash during file rename in external devices
Bug report: https://bugzilla.redhat.com/show_bug.cgi?id=1005660 Solution from: https://git.gnome.org/browse/nautilus/commit/src/nautilus-icon-view.c?h=gnome-3-2&id=a67212a
Diffstat (limited to 'src/file-manager/fm-icon-view.c')
-rw-r--r--src/file-manager/fm-icon-view.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/file-manager/fm-icon-view.c b/src/file-manager/fm-icon-view.c
index 888db702..6ab19c4e 100644
--- a/src/file-manager/fm-icon-view.c
+++ b/src/file-manager/fm-icon-view.c
@@ -2639,12 +2639,11 @@ fm_icon_view_icon_text_changed_callback (CajaIconContainer *container,
FMIconView *icon_view)
{
g_assert (CAJA_IS_FILE (file));
- g_assert (new_name != NULL);
/* Don't allow a rename with an empty string. Revert to original
* without notifying the user.
*/
- if (new_name[0] == '\0')
+ if ((new_name == NULL) || (new_name[0] == '\0'))
{
return;
}