Re: [libvirt] [PATCH] storage_backend.c: assure clang that inputvol can't be NULL

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

 



On Thu, Sep 03, 2009 at 11:18:00AM +0200, Jim Meyering wrote:
> clang was complaining that a NULL inputvol would be dereferenced
> in that "could not open..." diagnostic.
> 
> Since the two sole callers of this function are careful
> to call it only when inputvol is non-NULL, this is a good
> case for giving the parameter the nonnull attribute:

ACK. 

BTW, how exactly are you getting all these warnings/diagnostics ?
Are you merely compiling libvirt using clang & just collecting
the warnings, or is this some special static analysis tool ?

If we're going to start adding these non-null attributes, then 
I should hook the appropriate tool into autobuild.sh to validate
them regularly.

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