[libvirt] [PATCH 2/5] virt-aa-helper: Fix return value of add_file_path

Jamie Strandboge jamie at canonical.com
Fri Jul 23 22:19:34 UTC 2010


On Fri, 2010-07-23 at 19:24 +0200, Matthias Bolte wrote:
> Commit a8853344994a7c6aaca882a5e949ab5536821ab5 added this
> function and wrapped vah_add_file in it. vah_add_file may
> return -1, 0, 1. It returns 1 in case the call to valid_path
> detects a restricted file. The original code treated a return
> value != 0 as error. The refactored code treats a return
> value < 0 as error. This triggers segfault in virt-aa-helper
> and breaks virt-aa-helper-test for the restricted file tests.
> 
> Make sure that add_file_path returns -1 on error.

ACK

-- 
Jamie Strandboge             | http://www.canonical.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100724/743d816f/attachment-0001.sig>


More information about the libvir-list mailing list