summaryrefslogtreecommitdiff
path: root/data/openssh/_metadata/prerm
diff options
context:
space:
mode:
Diffstat (limited to 'data/openssh/_metadata/prerm')
-rwxr-xr-xdata/openssh/_metadata/prerm3
1 files changed, 2 insertions, 1 deletions
diff --git a/data/openssh/_metadata/prerm b/data/openssh/_metadata/prerm
index b717b6b1c..17abc80ef 100755
--- a/data/openssh/_metadata/prerm
+++ b/data/openssh/_metadata/prerm
@@ -1,3 +1,4 @@
#!/bin/sh
-/bin/launchctl unload /Library/LaunchDaemons/com.openssh.sshd.plist
+! /bin/launchctl list com.openssh.sshd &>/dev/null ||
+ /bin/launchctl unload /Library/LaunchDaemons/com.openssh.sshd.plist
exit 0