ofono_client: Improve log around Scan() failure

Change-Id: I8558d7fe41c155db2a9710e1eccf15b6499f24ef
This commit is contained in:
Pau Espin 2017-06-13 16:59:19 +02:00
parent cc5b5a2987
commit 910f3a1107
1 changed files with 3 additions and 1 deletions

View File

@ -418,9 +418,11 @@ class Modem(log.Origin):
# the registering succeeds while we are still waiting for Scan() to finsih.
# So far the easiest seems to check if we are now registered and
# otherwise schedule a scan again.
self.err('Scan() failed:', e)
self.err('Scan() failed, retrying if needed:', e)
if not self.is_connected(mcc_mnc):
self.schedule_scan_register(mcc_mnc)
else:
self.log('Already registered with network', mcc_mnc)
def scan_cb_register_automatic(self, scanned_operators, mcc_mnc):
self.dbg('scanned operators: ', scanned_operators);