All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel J Walsh <dwalsh@redhat.com>
To: Joshua Brindle <jbrindle@tresys.com>
Cc: Stephen Smalley <sds@tycho.nsa.gov>, SE Linux <selinux@tycho.nsa.gov>
Subject: Re: Patch to load_policy to enforce quiet option
Date: Thu, 30 Nov 2006 11:57:56 -0500	[thread overview]
Message-ID: <456F0D94.2030407@redhat.com> (raw)
In-Reply-To: <456F0580.7070003@tresys.com>

Joshua Brindle wrote:
> Daniel J Walsh wrote:
>>
>>
>> ------------------------------------------------------------------------
>>
>> diff --exclude-from=exclude --exclude POTFILES.in --exclude='*.po' 
>> --exclude='*.pot' -N -u -r 
>> nsapolicycoreutils/load_policy/load_policy.c 
>> policycoreutils-1.33.5/load_policy/load_policy.c
>> --- nsapolicycoreutils/load_policy/load_policy.c    2006-11-16 
>> 17:14:31.000000000 -0500
>> +++ policycoreutils-1.33.5/load_policy/load_policy.c    2006-11-28 
>> 10:44:25.000000000 -0500
>> @@ -50,12 +50,12 @@
>>      nargs = argc - optind;
>>      if (nargs > 2)
>>          usage(argv[0]);
>> -    if (nargs >= 1) {
>> -        fprintf(stderr,
>> -            "%s:  Warning!  Policy file argument (%s) is no longer 
>> supported, installed policy is always loaded.  Continuing...\n",
>> -            argv[0], argv[optind++]);
>> +    if (nargs >= 1 && !quiet) {
>> +            fprintf(stderr,
>> +                "%s:  Warning!  Policy file argument (%s) is no 
>> longer supported, installed policy is always loaded.  Continuing...\n",
>> +                argv[0], argv[optind++]);
>>      }
>> -    if (nargs == 2) {
>> +    if (nargs == 2 && ! quiet) {
>>          fprintf(stderr,
>>              "%s:  Warning!  Boolean file argument (%s) is no longer 
>> supported, installed booleans file is always used.  Continuing...\n",
>>              argv[0], argv[optind++]);
>
>
> Hrm. Should quiet really squelch warnings? Also, it looks like 
> load_policy is using a deprecated interface to squelch other output 
> from libsepol, this should probably be fixed.
>
man load_policy
...
      -q     suppress warning messages.
...


I think this was originally added to stop things like boolean is no 
longer in this package.  It might not be necessary any longer,  but if 
we have it we should be consistant.

--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

  reply	other threads:[~2006-11-30 16:57 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-29 22:16 Patch to load_policy to enforce quiet option Daniel J Walsh
2006-11-30 16:23 ` Joshua Brindle
2006-11-30 16:57   ` Daniel J Walsh [this message]
2006-12-06 17:16     ` Karl MacMillan
2006-12-12 18:01       ` Stephen Smalley
2007-01-03 16:15 ` Karl MacMillan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=456F0D94.2030407@redhat.com \
    --to=dwalsh@redhat.com \
    --cc=jbrindle@tresys.com \
    --cc=sds@tycho.nsa.gov \
    --cc=selinux@tycho.nsa.gov \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.