fix: fix crash with brokenfocus and camera-streamer (#224)
If one cam with `ustreamer` is defined it will run `brokenfocus` for every cam defined. This will lead to a crash with `brokenfocus` devices with mode `camera-streamer`. This PR fixes this issue and will only run `brokenfocus` for devices with mode `ustreamer`.
This commit is contained in:
parent
4feaab7249
commit
fd22d11d9b
@ -24,7 +24,7 @@ run_mjpg() {
|
|||||||
run_ustreamer "${instance}" &
|
run_ustreamer "${instance}" &
|
||||||
done
|
done
|
||||||
blockyfix
|
blockyfix
|
||||||
brokenfocus
|
brokenfocus "${cams}"
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -116,7 +116,7 @@ function brokenfocus {
|
|||||||
|
|
||||||
function main {
|
function main {
|
||||||
local cur_val conf_val device
|
local cur_val conf_val device
|
||||||
for cam in $(configured_cams); do
|
for cam in ${1}; do
|
||||||
device="$(get_param "cam ${cam}" device)"
|
device="$(get_param "cam ${cam}" device)"
|
||||||
cur_val="$(get_current_value "${device}")"
|
cur_val="$(get_current_value "${device}")"
|
||||||
conf_val="$(get_conf_value "${cam}")"
|
conf_val="$(get_conf_value "${cam}")"
|
||||||
@ -133,7 +133,7 @@ function brokenfocus {
|
|||||||
}
|
}
|
||||||
|
|
||||||
### MAIN
|
### MAIN
|
||||||
main
|
main "${1}"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user