From mboxrd@z Thu Jan 1 00:00:00 1970 From: ZhouPeng Subject: Re: [PATCH]tools/libxl: fix a bug in libxl__build_device_model_args_new. info->vncpasswd can't be empty if info->vncpasswd != NULL Date: Fri, 15 Apr 2011 17:36:57 +0800 Message-ID: References: <4DA801C4.5060102@amd.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1306654256==" Return-path: In-Reply-To: <4DA801C4.5060102@amd.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Christoph Egger , ian.campbell@citrix.com Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org --===============1306654256== Content-Type: multipart/alternative; boundary=bcaec51dd18578957904a0f1c823 --bcaec51dd18578957904a0f1c823 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable 2011/4/15 Christoph Egger > On 04/15/11 10:33, ZhouPeng wrote: > >> Signed-off-by: Zhou Peng >> >> tools/libxl: fix a bug in libxl__build_device_model_args_new. >> info->vncpasswd can't be empty if info->vncpasswd !=3D NULL >> >> > NACK! This can info->vncpasswd[0] contains '\0' if you have > > > vncpasswd=3D'' > > in the guest config file. > " if (info->vncpasswd&& info->vncpasswd[0]) =93 can vncpasswd=3D'' in guest cfg file, when using upstream-qemu-xen and block vncpasswd=3D'passwd' Can it be reasonable? Christoph > > > diff -r 3f00c5faa12a tools/libxl/libxl_dm.c >> --- a/tools/libxl/libxl_dm.c Wed Apr 13 16:10:26 2011 +0100 >> +++ b/tools/libxl/libxl_dm.c Fri Apr 15 09:45:43 2011 +0800 >> @@ -209,7 +209,7 @@ static char ** libxl__build_device_model >> int display =3D 0; >> const char *listen =3D "127.0.0.1"; >> >> - if (info->vncpasswd&& info->vncpasswd[0]) { >> + if (info->vncpasswd&& !info->vncpasswd[0]) { >> assert(!"missing code for supplying vnc password to qemu"); >> } >> flexarray_append(dm_args, "-vnc"); >> >> -- >> Zhou Peng >> Operating System Technology Group >> Institute of Software, the Chinese Academy of Sciences (ISCAS) >> >> >> > > -- > ---to satisfy European Law for business letters: > Advanced Micro Devices GmbH > Einsteinring 24, 85689 Dornach b. Muenchen > Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd > Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen > Registergericht Muenchen, HRB Nr. 43632 > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel > --=20 Zhou Peng Operating System Technology Group Institute of Software, the Chinese Academy of Sciences (ISCAS) --bcaec51dd18578957904a0f1c823 Content-Type: text/html; charset=windows-1252 Content-Transfer-Encoding: quoted-printable

2011/4/15 Christoph Egger <Christoph.Egger@amd.com<= /a>>
On 04/15/11 10:33, ZhouPeng wrote:
Signed-off-by: Zhou Peng<zhoupeng@nfs.iscas.ac.cn>

tools/libxl: fix a bug in libxl__build_device_model_args_new. info->vncp= asswd can't be empty if info->vncpasswd !=3D NULL


NACK! =A0This can info->vncpasswd[0] contains '\0' if you have

=A0 vncpasswd=3D''

in the guest config file.

=A0" if (info->v= ncpasswd&& =A0info->vncpasswd[0]) =93 can
=A0 vncpasswd=3D&#= 39;' in guest cfg file, when using upstream-qemu-xen
=A0 and block = vncpasswd=3D'passwd'
=A0 Can it be reasonable?

Christoph


diff -r 3f00c5faa12a tools/libxl/libxl_dm.c
--- a/tools/libxl/libxl_dm.c =A0 =A0Wed Apr 13 16:10:26 2011 +0100
+++ b/tools/libxl/libxl_dm.c =A0 =A0Fri Apr 15 09:45:43 2011 +0800
@@ -209,7 +209,7 @@ static char ** libxl__build_device_model
=A0 =A0 =A0 =A0 =A0int display =3D 0;
=A0 =A0 =A0 =A0 =A0const char *listen =3D "127.0.0.1";

- =A0 =A0 =A0 =A0if (info->vncpasswd&& =A0info->vncpasswd[0])= {
+ =A0 =A0 =A0 =A0if (info->vncpasswd&& =A0!info->vncpasswd[0]= ) {
=A0 =A0 =A0 =A0 =A0 =A0 =A0assert(!"missing code for supplying vnc pa= ssword to qemu");
=A0 =A0 =A0 =A0 =A0}
=A0 =A0 =A0 =A0 =A0flexarray_append(dm_args, "-vnc");

--
Zhou Peng
Operating System Technology Group
Institute of Software, the Chinese Academy of Sciences (ISCAS)
<mailto:ailvpe= ng25@gmail.com>



--
---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Einsteinring 24, 85689 Dornach b. Muenchen
Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632


_______________________________________________
Xen-devel mailing list
Xen-deve= l@lists.xensource.com
http://l= ists.xensource.com/xen-devel



--
Zhou Peng
Operating = System Technology Group
Institute of Software, the Chinese Academy of Sc= iences (ISCAS)

--bcaec51dd18578957904a0f1c823-- --===============1306654256== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --===============1306654256==--