load_policy.c 459 B

123456789101112131415161718192021222324
  1. /*
  2. * load_policy
  3. * Author: Yuichi Nakamura <ynakam@hitachisoft.jp>
  4. *
  5. * Licensed under GPLv2, see file LICENSE in this source tree.
  6. */
  7. #include "libbb.h"
  8. int load_policy_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
  9. int load_policy_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
  10. {
  11. int rc;
  12. if (argv[1]) {
  13. bb_show_usage();
  14. }
  15. rc = selinux_mkload_policy(1);
  16. if (rc < 0) {
  17. bb_perror_msg_and_die("can't load policy");
  18. }
  19. return 0;
  20. }