[libvirt] [PATCH v3 4/5] qemu: Remove need for qemuBuildSecretInfoProps

Peter Krempa pkrempa at redhat.com
Mon Jun 6 11:31:20 UTC 2016


On Mon, Jun 06, 2016 at 07:16:29 -0400, John Ferlan wrote:
> 
> 
> On 06/06/2016 03:26 AM, Peter Krempa wrote:
> > On Fri, Jun 03, 2016 at 06:52:52 -0400, John Ferlan wrote:
> >> Just move the code into qemuBuildObjectSecretCommandLine.
> >>
> >> Signed-off-by: John Ferlan <jferlan at redhat.com>
> >> ---
> >>  src/qemu/qemu_command.c | 57 +++++++++++--------------------------------------
> >>  1 file changed, 12 insertions(+), 45 deletions(-)
> > 
> > Again. If this is going to be reused in the monitor then it doesn't make
> > sense to move it to the builder directly. If it's not going to be used
> > with the monitor then it doesn't make sense to use the json parser and
> > the object formatter to achieve the same at all since it's rather
> > untrivial code that can be achieved with a single printf.
> > 
> 
> Huh?  This patch just moves code from qemuBuildSecretInfoProps into
> qemuBuildObjectSecretCommandLine as the only caller to the former was
> the latter.
> 
> I can drop this though - it's not that important.

I'm pointing out that if there's no need to use the code to pass secret
objects via the monitor then we should not use the JSON to commandline
generator at all.

Moving of the code directly to the place where we format the command
line is a very apparent reason that it's not going to be used anywhere
besides the command line.




More information about the libvir-list mailing list