Explorar el Código

Fixed a file leak in the help message.

Thomas Flucke hace 6 años
padre
commit
700d6e67cc
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      src/distributer/distribute.sh

+ 1 - 1
src/distributer/distribute.sh

@@ -1,6 +1,5 @@
 #!/bin/sh
 
-readonly PIPE_NAME="$(mktemp /tmp/distributer-XXX.fifo)"
 readonly CONF_LIST="$1"
 readonly SERVER_LIST="$2"
 
@@ -30,6 +29,7 @@ run_server() {
 }
 
 main() {
+    PIPE_NAME="$(mktemp /tmp/distributer-XXX.fifo)"
     rm "$PIPE_NAME"
     mkfifo "$PIPE_NAME"
     sed '/^[[:space:]]*$/d' "$CONF_LIST" > "$PIPE_NAME" &