moved mkfifo outside netcat loop

master
KatolaZ 6 years ago
parent bfc10ee6b3
commit 6756f54d52
  1. 7
      gosher

@ -45,13 +45,12 @@ if [ -z "${MYNAME#gosher}" ]; then
trap cleanup 0 HUP INT TRAP TERM QUIT trap cleanup 0 HUP INT TRAP TERM QUIT
OUTF=${OPREFIX}$$
INF=${IPREFIX}$$
mkfifo -m 600 $OUTF $INF
while [ 1 -eq 1 ]; do while [ 1 -eq 1 ]; do
OUTF=${OPREFIX}$$
INF=${IPREFIX}$$
mkfifo -m 600 $OUTF $INF
./gosher_serve ${GOPHERDIR} <$INF >$OUTF & ./gosher_serve ${GOPHERDIR} <$INF >$OUTF &
${NETCAT} -vv -l -p ${PORT} >$INF <$OUTF ${NETCAT} -vv -l -p ${PORT} >$INF <$OUTF
rm $OUTF $INF
ret=$? ret=$?
done done
exit 0 exit 0

Loading…
Cancel
Save