Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-20 Thread Chris Lalancette
Matthias Bolte wrote: > 2009/8/20 Chris Lalancette : >> Matthias Bolte wrote: >>> Hi, >>> >>> I came across this line in the phypOpen function: >>> >>> char string[strlen(conn->uri->path)]; >>> >>> Here the path part of the given URI is used without checking it for >>> NULL, this can cause a segfau

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-20 Thread Matthias Bolte
2009/8/20 Chris Lalancette : > Matthias Bolte wrote: >> Hi, >> >> I came across this line in the phypOpen function: >> >> char string[strlen(conn->uri->path)]; >> >> Here the path part of the given URI is used without checking it for >> NULL, this can cause a segfault as strlen expects a string !=

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-20 Thread Chris Lalancette
Matthias Bolte wrote: > Hi, > > I came across this line in the phypOpen function: > > char string[strlen(conn->uri->path)]; > > Here the path part of the given URI is used without checking it for > NULL, this can cause a segfault as strlen expects a string != NULL. > Beside that uuid_db and conn

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-16 Thread Matthias Bolte
2009/8/14 Eduardo Otubo : > On Fri, 2009-08-07 at 15:35 +0200, Chris Lalancette wrote: >> Matthias Bolte wrote: >> > Hi, >> > >> > I came across this line in the phypOpen function: >> > >> > char string[strlen(conn->uri->path)]; >> > >> > Here the path part of the given URI is used without checking

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-14 Thread Eduardo Otubo
On Fri, 2009-08-07 at 15:35 +0200, Chris Lalancette wrote: > Matthias Bolte wrote: > > Hi, > > > > I came across this line in the phypOpen function: > > > > char string[strlen(conn->uri->path)]; > > > > Here the path part of the given URI is used without checking it for > > NULL, this can cause

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-11 Thread Daniel P. Berrange
On Fri, Aug 07, 2009 at 02:50:19PM +0200, Matthias Bolte wrote: > Hi, > > I came across this line in the phypOpen function: > > char string[strlen(conn->uri->path)]; > > Here the path part of the given URI is used without checking it for > NULL, this can cause a segfault as strlen expects a stri

Re: [libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-07 Thread Chris Lalancette
Matthias Bolte wrote: > Hi, > > I came across this line in the phypOpen function: > > char string[strlen(conn->uri->path)]; > > Here the path part of the given URI is used without checking it for > NULL, this can cause a segfault as strlen expects a string != NULL. Heh, it's worse than that; th

[libvirt] Power Hypervisor: Fix potential segfault and memleak in phypOpen

2009-08-07 Thread Matthias Bolte
Hi, I came across this line in the phypOpen function: char string[strlen(conn->uri->path)]; Here the path part of the given URI is used without checking it for NULL, this can cause a segfault as strlen expects a string != NULL. Beside that uuid_db and connection_data leak in case of an error. I