source: trunk/debathena/config/reactivate/debian/policy-rc.d @ 25019

Revision 25019, 589 bytes checked in by jdreed, 14 years ago (diff)
In reactivate: * policy-rc.d should only return the cups daemons that exist (Trac #701). Fix plagiarized from debathena-cupsys-config's restart_cups.sh
  • Property svn:executable set to *
Line 
1#!/bin/sh
2
3if [ "--daemons" = "$1" ]; then
4    [ -e /etc/init.d/cups ] && rcname=cups || rcname=cupsys
5    echo $rcname
6    exit
7fi
8
9case "$2" in
10    \(*\))
11        exit 101
12        ;;
13esac
14
15# If nobody's logged in, follow the default policy
16if ! [ -e /var/run/athena-login ]; then
17    exit 0
18elif [ -e /ClusterLogin ]; then
19    case "$1" in
20        cups|cupsys)
21            exit 0
22            ;;
23        *)
24            exit 101
25            ;;
26    esac
27else
28    case "$1" in
29        cups|cupsys)
30            exit 101
31            ;;
32        *)
33            exit 0
34            ;;
35    esac
36fi
Note: See TracBrowser for help on using the repository browser.