[apparmor] [PATCH 8/8] Convert codomain to a class

Tyler Hicks tyhicks at canonical.com
Fri Sep 27 22:33:27 UTC 2013


On 2013-09-27 14:56:34, John Johansen wrote:
> On 09/13/2013 09:32 AM, Steve Beattie wrote:
> > On Wed, Sep 11, 2013 at 01:47:47AM -0700, Tyler Hicks wrote:
> >> From: John Johansen <john.johansen at canonical.com>
> >>
> >> Convert the codomain to a class, and the policy lists that store
> >> codomains to stl containers instead of glibc twalk.
> >>
> >> Signed-off-by: John Johansen <john.johansen at canonical.com>
> >> [tyhicks: Merge with dbus changes and process_file_entries() cleanup]
> >> Signed-off-by: Tyler Hicks <tyhicks at canonical.com>
> > 
> > This patch strips out the #ifdef UNIT_TEST bits from parser.h and
> > adds an #include <unit_test.h> in appropriate places; however, it
> > looks like the separated out unit_test.h file was not added to the
> > git/guilt/whatever patch.
> > 
> > Presumably, it would look something like the following:
> > 
> yeah largely the same, basically some includes and defines
> 
> 
> the diff of steves to mine is below

Thanks, John! I've applied Steve's patch, followed by your patch.

Tyler

> 
> ---
> 
> 
> --- /tmp/unit_test.h	2013-09-27 14:55:12.237597631 -0700
> +++ unit_test.h	2013-09-27 14:54:49.881596588 -0700
> @@ -15,9 +15,8 @@
>   *   along with this program; if not, contact Novell, Inc. or Canonical
>   *   Ltd.
>   */
> -
> -#ifndef __UNIT_TEST_H
> -#define __UNIT_TEST_H
> +#ifndef __AA_UNIT_TEST_H
> +#define __AA_UNIT_TEST_H
>  
>  #ifdef UNIT_TEST
>  /* For the unit-test builds, we must include function stubs for stuff that
> @@ -25,6 +24,13 @@
>   * in parser_common.c.
>   */
>  
> +#include <stdarg.h>
> +#include <stdlib.h>
> +#include <linux/limits.h>
> +
> +#undef _
> +#define _(s) (s)
> +
>  /* parser_yacc.y */
>  void yyerror(const char *msg, ...)
>  {
> @@ -48,4 +54,4 @@
>  
>  #endif /* UNIT_TEST */
>  
> -#endif /* __UNIT_TEST_H */
> +#endif /* __AA_UNIT_TEST_H */
> 
> 
> -- 
> AppArmor mailing list
> AppArmor at lists.ubuntu.com
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/apparmor
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <https://lists.ubuntu.com/archives/apparmor/attachments/20130927/a0aca162/attachment.pgp>


More information about the AppArmor mailing list