[Libguestfs] [PATCH 0/2] builder: Choose better weights in the planner.

Pino Toscano ptoscano at redhat.com
Tue Oct 3 10:25:02 UTC 2017


On Monday, 2 October 2017 23:43:53 CEST Richard W.M. Jones wrote:
> It started out as "this'll be just a simple fix ..."
> and turned into something a bit over-engineered in the end.
> 
> Here it is anyway.

(replying here, since my comments span both patches)

Even if we are supporting Linux only at the moment, IMHO it would be a
better idea to not expose f_type as part of the statvfs struct, since
it is not POSIX.  After all, it is not yet used by callers of StatVFS.

Instead, I'd implement directly is_remote in C (directly in builder),
calling directly fstatfs, and using the various *_MAGIC defines
provided by linux/magic.h.  This approach avoids duplicating in OCaml
the IDs of the various filesystems, and makes it easier to port to
other OSes.

-- 
Pino Toscano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part.
URL: <http://listman.redhat.com/archives/libguestfs/attachments/20171003/9c756893/attachment.sig>


More information about the Libguestfs mailing list