From e050411289bdac03ea2c45b8448ee6e812e6bae1 Mon Sep 17 00:00:00 2001 From: "jamiewalch@google.com" Date: Fri, 11 May 2012 18:41:00 +0000 Subject: Require an explicit command-line option from launchd. Without an explicit command-line option to run the host, we can't add functionality to the script because any version skew between the web-app and host components could cause the host to be run at the wrong time. BUG=None TEST=Manual Review URL: https://chromiumcodereview.appspot.com/10384126 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@136622 0039d316-1c4b-4281-b951-d872f2087c98 --- .../host/installer/mac/LaunchAgents/org.chromium.chromoting.plist | 1 + .../mac/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'remoting') diff --git a/remoting/host/installer/mac/LaunchAgents/org.chromium.chromoting.plist b/remoting/host/installer/mac/LaunchAgents/org.chromium.chromoting.plist index a7ca612..3831649 100644 --- a/remoting/host/installer/mac/LaunchAgents/org.chromium.chromoting.plist +++ b/remoting/host/installer/mac/LaunchAgents/org.chromium.chromoting.plist @@ -16,6 +16,7 @@ ProgramArguments /Library/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh + --run-from-launchd diff --git a/remoting/host/installer/mac/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh b/remoting/host/installer/mac/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh index 9e01d27..2a5845e 100755 --- a/remoting/host/installer/mac/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh +++ b/remoting/host/installer/mac/PrivilegedHelperTools/org.chromium.chromoting.me2me.sh @@ -82,6 +82,9 @@ elif [[ "$1" = "--enable" ]]; then elif [[ "$1" = "--save-config" ]]; then echo $$ cat > "$CONFIG_FILE" -else +elif [[ "$1" = "--run-from-launchd" ]]; then run_host +else + echo $$ + exit 1 fi -- cgit v1.1