[apparmor] [patch] [37/38] Drop severity rank() dispatcher

Steve Beattie steve at nxnw.org
Mon Sep 26 23:32:09 UTC 2016


On Fri, Aug 12, 2016 at 11:07:41PM +0200, Christian Boltz wrote:
> rank() in severity.py is a dispatcher that calls the needed function
> (rank_path(), rank_capability() based on the parameter. Since all
> calling code knows what rule type it is handling, this dispatcher is
> superfluous - the calling code can call rank_path() or rank_capability()
> directly.
> 
> This patch drops rank() and switches the remaining users of rank() to
> call the rank_*() functions directly. For the tests, this means to drop
> the CAP_ prefix because rank_capability doesn't expect this prefix.
> 
> [ 37-drop-severity-rank.diff ]

Acked-by: Steve Beattie <steve at nxnw.org>. Thanks.

-- 
Steve Beattie
<sbeattie at ubuntu.com>
http://NxNW.org/~steve/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/apparmor/attachments/20160926/41ff4776/attachment.pgp>


More information about the AppArmor mailing list