Test with a secondary UNIX socket

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson 2019-11-07 18:58:47 +01:00
parent 4376def121
commit 939a28f6f8
3 changed files with 7 additions and 3 deletions

View File

@ -5,7 +5,10 @@ fi
. ${srcdir}/test.rc
MSG="foobar"
MSG2="xyzzy"
../src/logger -u ${SOCK} ${MSG}
grep ${MSG} ${LOG}
../src/logger -u ${ALTSOCK} ${MSG2}
grep ${MSG2} ${LOG}

View File

@ -20,9 +20,9 @@ cat <<EOF > ${CONFD}/bar.conf
*.* @127.0.0.2
EOF
../src/syslogd -b :${PORT} -d -n -f ${CONF} -p ${SOCK} &
../src/syslogd -b :${PORT} -d -n -f ${CONF} -p ${SOCK} -p ${ALTSOCK} &
echo "$!" > ${PID}
sleep 1
sleep 2
kill -USR1 `cat ${PID}`
sleep 1

View File

@ -7,6 +7,7 @@ CAP=/tmp/${NM}.pcapng
CONF=/tmp/${NM}.conf
CONFD=/tmp/${NM}.d
SOCK=/tmp/${NM}.sock
ALTSOCK=/tmp/${NM}-alt.sock
PORT=5514
export SYSLOG_UNIX_PATH=${SOCK}