From: Michael Tremer Date: Tue, 18 Aug 2015 19:24:58 +0000 (+0200) Subject: Remove some unused code X-Git-Tag: 007~24 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ed75c16d8ef0ec9d41d4111b94cddbbc5cc6435c;p=network.git Remove some unused code Signed-off-by: Michael Tremer --- diff --git a/src/functions/functions.ports b/src/functions/functions.ports index 39c7fb66..8af5619e 100644 --- a/src/functions/functions.ports +++ b/src/functions/functions.ports @@ -156,29 +156,15 @@ port_is_up() { } port_new() { - #local port=${1} - #shift - # - #if port_exists ${port}; then - # error "Port '${port}' does already exist." - # return ${EXIT_ERROR} - #fi - - local hook=${1} + local hook="${1}" shift - if ! hook_exists port ${hook}; then + if ! hook_exists port "${hook}"; then error "Port hook '${hook}' does not exist." return ${EXIT_ERROR} fi - #port_edit ${port} ${hook} $@ - # - #if [ $? -ne ${EXIT_OK} ]; then - # port_destroy ${port} - #fi - - hook_exec port ${hook} new $@ + hook_exec port "${hook}" new $@ } port_destroy() {