summaryrefslogtreecommitdiffstats
path: root/contrib/dnsmasq_MacOSX/DNSmasq
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/dnsmasq_MacOSX/DNSmasq')
-rwxr-xr-xcontrib/dnsmasq_MacOSX/DNSmasq22
1 files changed, 22 insertions, 0 deletions
diff --git a/contrib/dnsmasq_MacOSX/DNSmasq b/contrib/dnsmasq_MacOSX/DNSmasq
new file mode 100755
index 0000000..6b62118
--- /dev/null
+++ b/contrib/dnsmasq_MacOSX/DNSmasq
@@ -0,0 +1,22 @@
+#!/bin/sh
+. /etc/rc.common
+
+StartService() {
+ if [ "${DNSMASQ:=-NO-}" = "-YES-" ] ; then
+ /usr/local/sbin/dnsmasq -q -n
+ fi
+}
+
+StopService() {
+ pid=`GetPID dnsmasq`
+ if [ $? -eq 0 ]; then
+ kill $pid
+ fi
+}
+
+RestartService() {
+ StopService "$@"
+ StartService "$@"
+}
+
+RunService "$1"