Gnome-VFS hal patch - found reason for computer vfolder crash

John (J5) Palmieri johnp at redhat.com
Wed Jun 2 19:44:10 PDT 2004


I have finally tracked down the mysterious cause of the Computer
v-folder crashing in the hal patch for Gnome-VFS.  It seems that the
display name is being encoded and used as the uri in the do_open
function in computer-method.c.  This causes problems with my / and /boot
mounts because they are encoded such as %2Fboot (%2F = '/').
gnome_vfs_uri_extract_short_name calls gnome_vfs_unescape_string and
specifies that '/' is an illegal character.  
gnome_vfs_unescape_string subsequently returns a NULL because it
encountered the escaped '/' sequence.  This NULL is then strcmp'ed in
do_open which causes the crash.

I am not sure what the best way to fix this is.  Should it be fixed in
the computer module, libgnome-vfs or hal patch? Should all Unix mounts
just be taken out of the equation (/ and /boot are set not to be user
visible, why put them into the list of drives)?  Can we simply replace
the '/' with some other character?  Is there a better way we can name
volumes?  Can we decouple the uri used by do_open and the display name? 
Just a couple of questions I wanted to throw out before I go ahead and
fix this.

-- 
John (J5) Palmieri
Associate Software Engineer
Desktop Group
Red Hat, Inc.
Blog: http://martianrock.com


_______________________________________________
hal mailing list
hal at freedesktop.org
http://freedesktop.org/mailman/listinfo/hal



More information about the Hal mailing list