summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTest_User <hax@andrewyu.org>2023-08-25 17:56:13 -0400
committerTest_User <hax@andrewyu.org>2023-08-25 17:56:13 -0400
commite5a21f16ce6544f5291af4e5413388b9a576d68f (patch)
tree7c1a8b1cb1b35ae45f40b6d4b408c8584e3728cc
parente214ef43325776321807f72cc4b266c23165da2c (diff)
downloadcoupserv-e5a21f16ce6544f5291af4e5413388b9a576d68f.tar.gz
coupserv-e5a21f16ce6544f5291af4e5413388b9a576d68f.zip
Fix socat vs HaxServ race
-rwxr-xr-xrerun.sh5
1 files changed, 4 insertions, 1 deletions
diff --git a/rerun.sh b/rerun.sh
index 5ba2e96..7f28b5c 100755
--- a/rerun.sh
+++ b/rerun.sh
@@ -1,6 +1,9 @@
#!/usr/bin/env bash
{
- socat -L'lock' 'UNIX-LISTEN:./s2s' 'OPENSSL:irc.andrewyu.org:7005' &
+ socat -L'lock' 'UNIX-LISTEN:./s2s,fork' 'OPENSSL:irc.andrewyu.org:7005' &
+ while ! [ -S ./s2s ]; do
+ sleep 0.1
+ done
start=`date -u +%s`
./haxserv
uptime=$((`date -u +%s` - $start))