Skip to content

Commit

Permalink
regress: fix quit()
Browse files Browse the repository at this point in the history
  • Loading branch information
omar-polo committed Aug 3, 2024
1 parent 5c44bf9 commit 36d6d35
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion regress/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -194,11 +194,12 @@ count() {
}

quit() {
pid="$(cat gmid.pid || true)"
pid="$(cat gmid.pid || true)" 2>/dev/null
if [ "$pid" != "" ]; then
kill $pid || true
wait || true
fi
rm gmid.pid
}

onexit() {
Expand Down
4 changes: 2 additions & 2 deletions regress/tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -523,15 +523,15 @@ test_ipv6_server() {
}

test_high_prefork() {
kill "$(cat gmid.pid)" 2>/dev/null || true
quit

setup_simple_test 'prefork 12'

fetch /
check_reply "20 text/gemini" "# hello world" || return 1

dont_check_server_alive=yes
kill "$(cat gmid.pid)" 2>/dev/null || true
quit
}

test_proxy_protocol_v1() {
Expand Down

0 comments on commit 36d6d35

Please sign in to comment.