[rhinstaller/blivet/pulls/33 f21-branch] Allow passing fractional MiB values to vgcreate -s option

mulkieran installerbot-noreply at redhat.com
Wed Mar 4 19:04:59 UTC 2015


Yes, this is for f21 branch. But my theory is that this code in libblockdev's vgcreate method:

```
argv[0] = "vgcreate";
argv[1] = "-s";
argv[2] = g_strdup_printf ("%"G_GUINT64_FORMAT"b", pe_size);
argv[3] = name;
```
indicates that lvm can accept bytes specification for pe size. Otherwise, some failure would already have been noticed. So why not just give it bytes in f21 branch? That way, it has to make an active effort to lose precision, whereas if it interprets the input
string as a floating point number it loses precision without any extra effort.

It strikes me that passing the value with the smallest units is probably often a good bet for these
external tools anyway.
-- 
To view this pull request on github, visit https://github.com/rhinstaller/blivet/pull/33


More information about the anaconda-patches mailing list