[patch] Handle special chars in mtab

Sjoerd Simons sjoerd at luon.net
Mon Dec 20 09:57:52 PST 2004


On Mon, Dec 20, 2004 at 11:04:10AM -0500, David Zeuthen wrote:
> On Sun, 2004-12-19 at 20:31 +0100, Sjoerd Simons wrote:
> > Hi,
> > 
> >   Several characters in mountpoints in /etc/mtab are encoded in octal form
> >   (space, tab, newline etc). Current hal uses that directly which confuses
> >   several other tools in the stack. Attached patch puts it back in plain text
> >   again.
> 
> Can you elaborate a bit more about what problems this patch solves?

Ofcourse, when mounting a drive at a mountpoint with a space. /etc/mtab will
show something like this:
  /dev/sda1 /media/test\040label vfat ...

Without the patch volume.mount_point will be '/media/test\040label', which
something like gvm passed directly on to nautilus. Causing a nice nautilus
error dialog for the user..

With the patch it will be '/media/test label' and everything just works :)

  Sjoerd
-- 
Waste not fresh tears over old griefs.
		-- Euripides
_______________________________________________
hal mailing list
hal at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/hal



More information about the Hal mailing list