[pkg-fso-commits] [SCM] FSO frameworkd Debian packaging branch, debian, updated. upstream/0.9.5.5-717-g0f98819

Michael 'Mickey' Lauer mickey at vanille-media.de
Sat Aug 6 08:18:20 UTC 2011


The following commit has been merged in the debian branch:
commit fb001f3ce766143a714d66efdcffaf1e9018b75f
Author: Michael Kurz <betheg at bitcloner.org>
Date:   Fri Sep 4 12:37:08 2009 +0200

    ogsmd: substitute empty provider string with information from network.tab. Fixes FSO #466
    Some providers are too new for the modem, hence we get something like:
    +COPS: (2," "," ","26201"),(1,"o2 - de","o2 - de","26207"),(1,"E-Plus","E-Plus","26203"),(1,"Vodafone.de","Vodafone","26202")
    This fixes it by checking our (hopefully more current) provider database.

diff --git a/framework/subsystems/ogsmd/modems/abstract/mediator.py b/framework/subsystems/ogsmd/modems/abstract/mediator.py
index b26e129..4fce25e 100644
--- a/framework/subsystems/ogsmd/modems/abstract/mediator.py
+++ b/framework/subsystems/ogsmd/modems/abstract/mediator.py
@@ -1308,6 +1308,14 @@ class NetworkListProviders( NetworkMediator ): # a{sv}
                 if act is None or act == "":
                     act = "0" # AcT defaults to GSM
                 act = const.REGISTER_ACT[int(act)]
+                if not name.strip():
+                     name = const.NETWORKS.get( ( int( index[:3]), int( index[3:] ) ), {} )
+                     if "brand" in name:
+                         name = name["brand"]
+                     elif "operator" in name:
+                         name = name["operator"]
+                     else:
+                         name = "Unknown"
                 result.append( ( index, status, name, shortname, act ) )
             self._ok( result )
         else:

-- 
FSO frameworkd Debian packaging



More information about the pkg-fso-commits mailing list