Hi Stephen,

Thanks for the feedback. I removed the unnecessary initializations you pointed 
out and added symtab_destroy(). I will re-submit it to selinux mailing list.

Thanks,
Alice
________________________________________
From: Stephen Smalley [[email protected]]
Sent: Wednesday, January 02, 2013 10:20 AM
To: Alice Chu
Cc: [email protected]; William Roberts
Subject: Re: Fixing libsepol issues found by Klocwork

On 12/21/2012 08:40 PM, Alice Chu wrote:
> Hello,
>
> This is for external/libsepol.
>
> Attached you will find the Klocwork report on external/libsepol and my fix in 
> a patch. The change is done on master branch.
> Some of the Klocwork findings are, I think, false positive. I keep them in 
> the report so that you can go over one more time.
> Please review my change and let me know any additional correction I should 
> make.
>
> Thank you very much for the feedback.

As with the checkpolicy patch, this should go first to selinux list
since libsepol in Android is a direct copy of the upstream SELinux
libsepol.  And it would help to have the patch inlined for review.  A
few obvious initial comments:

- Various NULL initializations and tests for NULL appear to be
unnecessary to me.  Did you confirm that they are truly needed or just
blindly "fix" based on the output of your tool?  Let's not change code
just to appease some tool.

- It would be cleaner to define a symtab_destroy or symtab_free helper
and use it throughout.



--
This message was distributed to subscribers of the seandroid-list mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe seandroid-list" without quotes as the message.

Reply via email to