Hi!
> +#ifdef HAVE_LIBCAP
>       for (; i <= CAP_LAST_CAP; i++) {
>  #if HAVE_DECL_PR_CAPBSET_READ
>               ret = prctl(PR_CAPBSET_READ, i);
> @@ -71,6 +72,9 @@ int check_remaining_caps(int lastdropped)
>                       return -i;
>               }
>       }
> +#else
> +     printf("System doesn't support full POSIX capabilities.\n");

This message is useless, as when HAVE_LIBCAP is not defined the
check_remaining_caps() is never called from the main() or am I mistaken?

> +#endif
>       return 0;
>  }
>  
> @@ -79,6 +83,7 @@ int main(int argc, char *argv[])
>       int ret = 1;
>       int i;
>  
> +#ifdef HAVE_LIBCAP
>  #if HAVE_DECL_PR_CAPBSET_DROP
>       ret = prctl(PR_CAPBSET_READ, -1);
>  #else
> @@ -131,5 +136,8 @@ int main(int argc, char *argv[])
>               }
>       }
>       tst_resm(TPASS, "PR_CAPBSET_DROP tests passed\n");
> +#else
> +     printf("System doesn't support full POSIX capabilities.\n");
> +#endif
>       tst_exit();

I'm a little lost in the ifdefs, but this one should IMHO be:

tst_resm(TCONF, "System doesn't support full POSIX capabilities.\n"


The rest seems to be fine.

-- 
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to