libvirt/src/security
Eric Blake 8733303933 conf: avoid memleak on NULL path
I noticed that the apparmor code could request metadata even
for a cdrom with no media, which would cause a memory leak of
the hash table used to look for loops in the backing chain.
But even before that, we blindly dereferenced the path for
printing a debug statement, so it is just better to enforce
that this is only used on non-NULL names.

* src/util/virstoragefile.c (virStorageFileGetMetadata): Assume
non-NULL path.
* src/util/virstoragefile.h: Annotate this.
* src/security/virt-aa-helper.c (get_files): Fix caller.

Signed-off-by: Eric Blake <eblake@redhat.com>
2014-04-07 16:31:45 -06:00
..
security_apparmor.c conf: move host disk type to util/ 2014-04-01 10:38:13 -06:00
security_apparmor.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
security_dac.c util: move detection of shared filesystems 2014-04-01 10:38:14 -06:00
security_dac.h security: use a single function to set DAC user and group 2013-10-29 06:55:09 -06:00
security_driver.c Add virLogSource variables to all source files 2014-03-18 14:29:22 +00:00
security_driver.h security: add new internal function "virSecurityManagerGetBaseLabel" 2013-10-29 06:57:07 -06:00
security_manager.c Fix coverity-reported leak in virSecurityManagerGenLabel 2014-04-02 15:23:01 +02:00
security_manager.h security: add new internal function "virSecurityManagerGetBaseLabel" 2013-10-29 06:57:07 -06:00
security_nop.c security: add new internal function "virSecurityManagerGetBaseLabel" 2013-10-29 06:57:07 -06:00
security_nop.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
security_selinux.c util: move detection of shared filesystems 2014-04-01 10:38:14 -06:00
security_selinux.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
security_stack.c Use K&R style for curly braces in remaining files 2014-03-20 17:27:17 +01:00
security_stack.h security: fix #endif comment in security_stack.h 2012-12-20 19:55:54 +01:00
virt-aa-helper.c conf: avoid memleak on NULL path 2014-04-07 16:31:45 -06:00