Patch for 87286 - Nautilus crashes while closing window
- From: Damon Chaplin <damon ximian com>
- To: Nautilus List <nautilus-list gnome org>
- Subject: Patch for 87286 - Nautilus crashes while closing window
- Date: 10 Jul 2002 14:08:41 -0400
Simple patch for 87286:
Index: nautilus-program-choosing.c
===================================================================
RCS file:
/cvs/gnome/nautilus/libnautilus-private/nautilus-program-choosing.c,v
retrieving revision 1.58
diff -u -p -r1.58 nautilus-program-choosing.c
--- nautilus-program-choosing.c 28 Jun 2002 14:13:48 -0000 1.58
+++ nautilus-program-choosing.c 10 Jul 2002 17:31:38 -0000
@@ -666,8 +666,7 @@ nautilus_launch_desktop_file (const char
}
error = NULL;
- ditem = gnome_desktop_item_new_from_uri (desktop_file_uri,
- GNOME_DESKTOP_ITEM_LOAD_ONLY_IF_EXISTS,
+ ditem = gnome_desktop_item_new_from_uri (desktop_file_uri, 0,
&error);
if (error != NULL) {
message = g_strconcat (_("There was an error launching the
application.\n\n"
The problem is that gnome_desktop_item_new_from_uri() returns NULL
if the desktop item loaded OK but the executable doesn't exist
(since we passed the GNOME_DESKTOP_ITEM_LOAD_ONLY_IF_EXISTS flag).
But nautilus wasn't expecting NULL so it crashes.
The fix is to not pass GNOME_DESKTOP_ITEM_LOAD_ONLY_IF_EXISTS.
If the executable doesn't exist nautilus finds out when it
tries to run it, and displays a dialog.
Damon
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]