[Libguestfs] do_umount adjustment

Richard W.M. Jones rjones at redhat.com
Wed Aug 12 08:30:53 UTC 2009


On Wed, Aug 12, 2009 at 10:25:34AM +0200, Jim Meyering wrote:
> If do_umount is the only case like that (and it seems to be),
> a more local change is possible: if pathordevice starts with
> /sysroot/dev, remove the "/sysroot" part.
> 
> Not terribly pretty to add the prefix, and then to remove it
> right afterwards, but...

Ick.  Remember that "/sysroot" is not a constant.  It's the variables
sysroot and sysroot_len that contain the actual prefix.

Rich.

-- 
Richard Jones, Emerging Technologies, Red Hat  http://et.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 75 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora




More information about the Libguestfs mailing list