Wait in background

This commit is contained in:
Kroese 2023-05-03 05:24:27 +02:00 committed by GitHub
parent a0e9e2f3c0
commit 68b0e3b9b6

View File

@ -11,5 +11,5 @@ LENGTH="${#HTML}"
RESPONSE="HTTP/1.1 200 OK\nContent-Length: ${LENGTH}\nConnection: close\n\n$HTML\n\n"
while true; do
echo -en "$RESPONSE" | nc -lp "${1:-5000}";
echo -en "$RESPONSE" | nc -lp "${1:-5000}" & wait $!
done