diff options
author | Tim Clark <tim@lshift.net> | 2009-06-14 18:28:38 +0100 |
---|---|---|
committer | Tim Clark <tim@lshift.net> | 2009-06-14 18:28:38 +0100 |
commit | 87590309f26e2cb0ed0076947720aab967110720 (patch) | |
tree | 0f57a9c5fedc65ea83ce58fd58b09d29d0969c42 | |
parent | 094efd1826088a4634c3c1e41a281f3959f2af66 (diff) | |
download | rabbitmq-server-87590309f26e2cb0ed0076947720aab967110720.tar.gz |
Fixing up escaping of commandline argumentsbug20961
-rw-r--r-- | packaging/macports/net/rabbitmq-server/files/rabbitmq-script-wrapper | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/packaging/macports/net/rabbitmq-server/files/rabbitmq-script-wrapper b/packaging/macports/net/rabbitmq-server/files/rabbitmq-script-wrapper index b806049c..0d7118c4 100644 --- a/packaging/macports/net/rabbitmq-server/files/rabbitmq-script-wrapper +++ b/packaging/macports/net/rabbitmq-server/files/rabbitmq-script-wrapper @@ -1,20 +1,10 @@ #!/bin/bash -# Escape spaces and quotes, because shell is revolting. -for arg in "$@" ; do - # Escape quotes in parameters, so that they're passed through cleanly. - arg=$(sed -e 's/"/\\"/' <<-END - $arg - END - ) - CMDLINE="${CMDLINE} \"${arg}\"" -done - cd /var/lib/rabbitmq SCRIPT=`basename $0` if [ `id -u` = 0 ] ; then - sudo -u rabbitmq -H /usr/lib/rabbitmq/bin/${SCRIPT} ${CMDLINE} + sudo -u rabbitmq -H /usr/lib/rabbitmq/bin/${SCRIPT} "$@" else /usr/lib/rabbitmq/bin/${SCRIPT} echo -e "\nOnly root should run ${SCRIPT}\n" |