modemmanager: always reset the init_eps if not configured

The initial EPS is stored on the modem side. When establishing a connection,
it must therefore be deleted if no EPS has been configured. This is because
the system does not know whether one was configured previously.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
Florian Eckert authored and Florian Eckert committed 2025-09-04 08:35:09 +02:00
1 parent f49138b564
commit 246506690f
1 file changed
+4 -7
@@ -629,13 +629,10 @@ proto_modemmanager_setup() {
}
# set initial eps bearer settings
[ -z "${init_epsbearer}" ] || {
if [ -z "${init_epsbearer}" ]; then
modemmanager_init_epsbearer "none" "$device" "" "$apn"
else
case "$init_epsbearer" in
"none")
connectargs=""
modemmanager_init_epsbearer "none" \
"$device" "${connectargs}" "$apn"
;;
"default")
cliauth=""
for auth in $allowedauth; do
@@ -667,7 +664,7 @@ proto_modemmanager_setup() {
esac
# check error for init_epsbearer function call
[ "$?" -ne "0" ] && return 1
}
fi
if [ -z "${allowedmode}" ]; then
modemmanager_set_allowed_mode "$device" "$interface" "any"