mirror of
https://github.com/openwrt/packages.git
synced 2026-04-15 19:02:09 +00:00
modemmanager: add missing interface argument to function modemmanager_check_state
The variable interface is used in the sub-function 'modemmanager_check_state'. However, this is not an argument of the function and so the global value is used. Addding the variable as an function call argument fixes this. Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
committed by
Robert Marko
parent
64bd9e9d08
commit
cdda998996
@@ -355,8 +355,9 @@ modemmanager_check_state_locked() {
|
||||
|
||||
modemmanager_check_state() {
|
||||
local device="$1"
|
||||
local modemstatus="$2"
|
||||
local pincode="$3"
|
||||
local interface="$2"
|
||||
local modemstatus="$3"
|
||||
local pincode="$4"
|
||||
|
||||
local state
|
||||
|
||||
@@ -486,7 +487,7 @@ proto_modemmanager_setup() {
|
||||
}
|
||||
echo "modem available at ${modempath}"
|
||||
|
||||
modemmanager_check_state "$device" "${modemstatus}" "$pincode"
|
||||
modemmanager_check_state "$device" "$interface" "${modemstatus}" "$pincode"
|
||||
[ "$?" -ne "0" ] && return 1
|
||||
|
||||
# always cleanup before attempting a new connection, just in case
|
||||
|
||||
Reference in New Issue
Block a user