Index: /trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIIndicatorsPool.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIIndicatorsPool.cpp	(revision 54145)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIIndicatorsPool.cpp	(revision 54146)
@@ -318,4 +318,5 @@
         : UISessionStateStatusBarIndicator(pSession)
         , m_pTimerAutoUpdate(0)
+        , m_cMaxNetworkAdapters(0)
     {
         /* Assign state-icons: */
@@ -327,4 +328,8 @@
         connect(m_pSession, SIGNAL(sigMachineStateChange()),
                 this, SLOT(sltHandleMachineStateChange()));
+        /* Fetch maximum network adapters count: */
+        const CVirtualBox vbox = vboxGlobal().virtualBox();
+        const CMachine machine = m_pSession->machine();
+        m_cMaxNetworkAdapters = vbox.GetSystemProperties().GetMaxNetworkAdapters(machine.GetChipsetType());
         /* Create auto-update timer: */
         m_pTimerAutoUpdate = new QTimer(this);
@@ -388,9 +393,8 @@
         machine.GetGuestProperty("/VirtualBox/GuestInfo/Net/Count", strCount, iTimestamp, strFlags);
         bool fPropsValid = (u64Now - iTimestamp < UINT64_C(60000000000)); /* timeout beacon */
-        ulong uMaxCount = vboxGlobal().virtualBox().GetSystemProperties().GetMaxNetworkAdapters(machine.GetChipsetType());
         QStringList ipList, macList;
         if (fPropsValid)
         {
-            const int cAdapters = RT_MIN(strCount.toInt(), (int)uMaxCount);
+            const int cAdapters = RT_MIN(strCount.toInt(), m_cMaxNetworkAdapters);
             for (int i = 0; i < cAdapters; ++i)
             {
@@ -400,8 +404,8 @@
         }
 
-        /* Enumerate up to uMaxCount adapters: */
+        /* Enumerate up to m_cMaxNetworkAdapters adapters: */
         bool fAdaptersPresent = false;
         bool fCablesDisconnected = true;
-        for (ulong uSlot = 0; uSlot < uMaxCount; ++uSlot)
+        for (ulong uSlot = 0; uSlot < m_cMaxNetworkAdapters; ++uSlot)
         {
             const CNetworkAdapter &adapter = machine.GetNetworkAdapter(uSlot);
@@ -453,4 +457,6 @@
     /** Holds the auto-update timer instance. */
     QTimer *m_pTimerAutoUpdate;
+    /** Holds the maximum amount of the network adapters. */
+    int m_cMaxNetworkAdapters;
 };
 
