Re: [PATCH] domain_conf: vnc: preserve autoport value if no port was specified

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 26, 2017 at 04:30:31PM -0500, John Ferlan wrote:
> 
> 
> On 01/25/2017 12:26 PM, Pavel Hrdina wrote:
> > The issue is that if this graphics definition is provided:
> > 
> >   <graphics type='vnc' port='0'/>
> > 
> > it's parsed as:
> > 
> >   <graphics type='vnc' autoport='no'>
> >     <listen type='address'/>
> >   </graphics>
> > 
> > but if the resulting XML is parsed again the output is:
> > 
> >   <graphics type='vnc' port='-1' autoport='yes'>
> >     <listen type='address'/>
> >   </graphics>
> > 
> > and this should not happen.  The XML have to always remain the same
> > after it was already parsed by libvirt.
> > 
> > Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1383039
> > 
> > Signed-off-by: Pavel Hrdina <phrdina@xxxxxxxxxx>
> > ---
> >  src/conf/domain_conf.c                             |  2 ++
> >  .../generic-graphics-vnc-autoport-no.xml           | 30 ++++++++++++++++++++++
> >  tests/genericxml2xmltest.c                         |  1 +
> >  3 files changed, 33 insertions(+)
> >  create mode 100644 tests/genericxml2xmlindata/generic-graphics-vnc-autoport-no.xml
> > 
> 
> I know this is a VNC bug, but RDP has similar code which would seemingly
> have the same issue.

I've also checked the RDP code and tested it and it seemed that it didn't
have the same issue even though the code is the same.  However I've tested
it again and it does have the same issue, I'll send a patch for that as well.

> The SPICE code is a bit different (I assume it doesn't have the legacy
> compat issue). It doesn't set autoport when "port" is not supplied.
> 
> ACK for this change, though.

Thanks, I'll push it shortly.

Pavel

Attachment: signature.asc
Description: Digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux