mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Refine config directive token parsing. v6.0.135 (#4042)
make sure one directive token don't span more than two lines. try to fix #2228 --------- Co-authored-by: winlin <winlinvip@gmail.com>
This commit is contained in:
parent
6bbd461ec9
commit
baf22d01c1
9 changed files with 175 additions and 36 deletions
40
trunk/scripts/verify_confs.sh
Executable file
40
trunk/scripts/verify_confs.sh
Executable file
|
@ -0,0 +1,40 @@
|
|||
#!/bin/bash
|
||||
|
||||
TRUNK_DIR=$(dirname $(realpath -q $0))/..
|
||||
|
||||
pushd $TRUNK_DIR > /dev/null
|
||||
|
||||
SRS_EXE=$(pwd)/objs/srs
|
||||
|
||||
if [ ! -f ${SRS_EXE} ]; then
|
||||
echo "${SRS_EXE} not exist"
|
||||
exit -1
|
||||
fi
|
||||
|
||||
if [ ! -x ${SRS_EXE} ]; then
|
||||
echo "${SRS_EXE} not executable"
|
||||
exit -2
|
||||
fi
|
||||
|
||||
for f in conf/*.conf
|
||||
do
|
||||
if [ -f $f ]; then
|
||||
# skip below conf
|
||||
if [[ $f == "conf/full.conf" ||
|
||||
$f == "conf/hls.edge.conf" ||
|
||||
$f == "conf/nginx.proxy.conf" ||
|
||||
$f == "conf/include.vhost.conf" ]]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
${SRS_EXE} -t -c $f
|
||||
RET=$?
|
||||
if [ $RET -ne 0 ]; then
|
||||
echo "please check $f"
|
||||
popd > /dev/null
|
||||
exit $RET
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
popd > /dev/null
|
Loading…
Add table
Add a link
Reference in a new issue