[PATCH 05/16] conf: Move iothread formatter into a separate function

Peter Krempa pkrempa at redhat.com
Thu Jun 2 07:56:34 UTC 2022


On Thu, Jun 02, 2022 at 09:17:55 +0200, Michal Privoznik wrote:
> Formatting iothreads is currently open coded inside of
> virDomainDefFormatInternalSetRootName(). While this works, it
> makes the function needlessly long, especially if the formatting
> code will expand in near future. Therefore, move it into a
> separate function. At the same time, make
> virDomainDefIothreadShouldFormat() accept const domain definition
> so that the new function can also accept const domain definition.
> Formatters shouldn't need to change definition.
> 
> Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
> ---
>  src/conf/domain_conf.c | 42 +++++++++++++++++++++++++++---------------
>  1 file changed, 27 insertions(+), 15 deletions(-)

Reviewed-by: Peter Krempa <pkrempa at redhat.com>


More information about the libvir-list mailing list