Re: [libvirt] [PATCH] Fix activeDomainList handling

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

 



On Wed, Jan 14, 2009 at 08:27:36PM +0100, Jim Meyering wrote:
> John Levon <levon@xxxxxxxxxxxxxxxxx> wrote:
> > On Wed, Jan 14, 2009 at 10:53:51AM -0800, john.levon@xxxxxxx wrote:
> >
> >> Fix activeDomainList handling
> >>
> >> It must be NULLed out after free()ing.
> >
> > This one is incomplete - I didn't find the bug since I have to use
> > 0@xxxx with LIBVIRT_DEBUG. Annoyingly, Solaris printf requires %s
> > parameters to not be NULL, and the debug messages use this Linux feature
> > in several places... new patch soon
> 
> That glibc's printf functions accept a NULL parameter for a %s format
> directive is a *mis*feature.  As such, I think any code that relies on
> it is buggy, so patches would be most welcome.

Some kind of macro to make it easy to pass params to %s args
would make this less tedious to fix / easier to check

 #define nonnull(str) ((str) ? (str) : "<null>")

Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|

--
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]