GNOME Bugzilla – Bug 564327
Crash on ctrl-clicking URLs containing an invalid URL escape sequence
Last modified: 2008-12-13 18:28:35 UTC
I am seeing the following crash when I try to ctrl-click on a URL with an invalid escape sequence in gnome-terminal (for example, http://a/% or http://site.com/%2). To reproduce, type the URL http://a/% in a terminal and ctrl-click it. Hope this helps, let me know if I can provide any more information. crash.gnome.org was 503ing when this happened, so I have included the backtrace below: Distribution: Fedora release 10 (Cambridge) Gnome Release: 2.24.2 2008-11-25 (Red Hat, Inc) BugBuddy Version: 2.24.2 System: Linux 2.6.27.7-134.fc10.i686.PAE #1 SMP Mon Dec 1 22:30:53 EST 2008 i686 X Vendor: The X.Org Foundation X Vendor Release: 10503000 Selinux: Permissive Accessibility: Disabled GTK+ Theme: Nodoka Icon Theme: Fedora Memory status: size: 91365376 vsize: 91365376 resident: 20557824 share: 12685312 rss: 20557824 rss_rlim: 18446744073709551615 CPU usage: start_time: 1229120302 rtime: 216 utime: 176 stime: 40 cutime:1794 cstime: 552 timeout: 0 it_real_value: 0 frequency: 100 Backtrace was generated from '/usr/bin/gnome-terminal' [Thread debugging using libthread_db enabled] [New Thread 0xb7fd0760 (LWP 424)] [New Thread 0xb5387b90 (LWP 428)] 0x00110424 in __kernel_vsyscall ()
+ Trace 210743
Thread 1 (Thread 0xb7fd0760 (LWP 424))
----------- .xsession-errors --------------------- (gnome-terminal:32147): Vte-WARNING **: No handler for control sequence `device-control-string' defined. Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect ICEDTEAPLUGIN_DEBUG = (null) Initializing JVM... IcedTeaPlugin.cc:1647: Error: liveconnect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect OMF category 'System|Configuration|Configuration Tools' not recognised, ignoring. OMF category 'System|Configuration|Configuration Tools' not recognised, ignoring. OMF category 'System|Configuration|Configuration Tools' not recognised, ignoring. Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Cannot access memory at address 0x27 Cannot access memory at address 0x27 --------------------------------------------------
I'm sorry, looking at the backtrace one more time, I think it might have been more appropriate to file it under gvfs instead. Sorry for the noise.
Now that I know it's in gvfs, here's the backtrace with debugging symbols for gvfs installed: Distribution: Fedora release 10 (Cambridge) Gnome Release: 2.24.2 2008-11-25 (Red Hat, Inc) BugBuddy Version: 2.24.2 System: Linux 2.6.27.7-134.fc10.i686.PAE #1 SMP Mon Dec 1 22:30:53 EST 2008 i686 X Vendor: The X.Org Foundation X Vendor Release: 10503000 Selinux: Permissive Accessibility: Disabled GTK+ Theme: Nodoka Icon Theme: Fedora Memory status: size: 64073728 vsize: 64073728 resident: 20131840 share: 11563008 rss: 20131840 rss_rlim: 18446744073709551615 CPU usage: start_time: 1229120856 rtime: 1151 utime: 953 stime: 198 cutime:104 cstime: 51 timeout: 0 it_real_value: 0 frequency: 100 Backtrace was generated from '/usr/bin/gnome-terminal' [Thread debugging using libthread_db enabled] [New Thread 0xb7f6e760 (LWP 1137)] [New Thread 0xb3b0fb90 (LWP 1143)] 0x00110424 in __kernel_vsyscall ()
+ Trace 210744
Thread 1 (Thread 0xb7f6e760 (LWP 1137))
----------- .xsession-errors --------------------- Cannot access memory at address 0x27 Cannot access memory at address 0x27 Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect ** (nautilus:1377): WARNING **: Unable to add monitor: Not supported Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect (gnome-terminal:1137): Vte-WARNING **: No handler for control sequence `device-control-string' defined. Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Window manager warning: Attempt to perform window operation 20 on window none when operation 20 on none already in effect Cannot access memory at address 0x27 Cannot access memory at address 0x27 --------------------------------------------------
So apparently, g_vfs_decode_uri can return NULL, which I think ends up setting path to NULL in g_daemon_vfs_get_file_for_uri. Here's an untested patch to trunk that checks if path is NULL before continuing: Index: client/gdaemonvfs.c =================================================================== --- client/gdaemonvfs.c (revision 2134) +++ client/gdaemonvfs.c (working copy) @@ -428,7 +428,7 @@ return file; } - if (get_mountspec_from_uri (daemon_vfs, uri, &spec, &path)) + if (get_mountspec_from_uri (daemon_vfs, uri, &spec, &path) && path != NULL) { file = g_daemon_file_new (spec, path); g_mount_spec_unref (spec);
Thanks for the bug report. This particular bug has already been reported into our bug tracking system, but please feel free to report any further bugs you find. *** This bug has been marked as a duplicate of 546256 ***