[apparmor] [patch 12/12] regression tests: fix introspect.c compiler warnings
Seth Arnold
seth.arnold at canonical.com
Tue Dec 10 07:26:09 UTC 2013
On Tue, Dec 03, 2013 at 12:12:28PM -0800, Steve Beattie wrote:
> This patch annotates that a couple of values emitted on failure are
> of type size_t, eliminating a couple of compiler warnings.
>
> Signed-off-by: Steve Beattie <steve at nxnw.org>
Acked-by: Seth Arnold <seth.arnold at canonical.com>
> ---
> tests/regression/apparmor/introspect.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> Index: b/tests/regression/apparmor/introspect.c
> ===================================================================
> --- a/tests/regression/apparmor/introspect.c
> +++ b/tests/regression/apparmor/introspect.c
> @@ -1,5 +1,6 @@
> /*
> * Copyright (C) 2002-2005 Novell/SUSE
> + * Copyright (C) 2013 Canonical Ltd.
> *
> * This program is free software; you can redistribute it and/or
> * modify it under the terms of the GNU General Public License as
> @@ -69,14 +70,14 @@ int main(int argc, char *argv[])
> if (rc != strlen(profile) + strlen(mode) + 4) {
> /* rc includes mode. + 2 null term + 1 ( + 1 space */
> fprintf(stderr,
> - "FAIL: expected return len %d != actual %d\n",
> + "FAIL: expected return len %zd != actual %d\n",
> strlen(profile) + strlen(mode) + 4, rc);
> exit(1);
> }
> } else if (rc != strlen(profile) + 1) {
> /* rc includes null termination */
> fprintf(stderr,
> - "FAIL: expected return len %d != actual %d\n",
> + "FAIL: expected return len %zd != actual %d\n",
> strlen(profile) + 1, rc);
> exit(1);
> }
Thanks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: Digital signature
URL: <https://lists.ubuntu.com/archives/apparmor/attachments/20131209/6091086c/attachment.pgp>
More information about the AppArmor
mailing list