Browse Source

Fixing mpv length option for webradio check

Yann Weber 2 weeks ago
parent
commit
069dae7662
1 changed files with 2 additions and 1 deletions
  1. 2
    1
      checks/webradio.sh

+ 2
- 1
checks/webradio.sh View File

@@ -112,8 +112,9 @@ check_audiostream_mpv() {
112 112
 	then
113 113
 		logdate INFO "$tc_name: Running mpv on '$1' for ${time}s" 3
114 114
 	fi
115
+	run_time=$(expr $time + 2)
115 116
 	start_time=$(date "+%s")
116
-	$MPV --vo=null --ao=null --o=/dev/null --of=wav --length $time "$1" 1> /dev/null 2>/dev/null
117
+	$MPV --vo=null --ao=null --o=/dev/null --of=wav --end=$run_time "$1" 1> /dev/null 2>/dev/null
117 118
 	res=$?
118 119
 	stop_time=$(date "+%s")
119 120
 	run_time=$(( stop_time - start_time))

Loading…
Cancel
Save