Index: /trunk/src/VBox/Additions/common/VBoxService/VBoxServicePageSharing.cpp
===================================================================
--- /trunk/src/VBox/Additions/common/VBoxService/VBoxServicePageSharing.cpp	(revision 29471)
+++ /trunk/src/VBox/Additions/common/VBoxService/VBoxServicePageSharing.cpp	(revision 29472)
@@ -129,7 +129,7 @@
     do
     {
-        MEMORY_BASIC_INFORMATION MemInfo[16];
-
-        SIZE_T ret = VirtualQueryEx(hProcess, pBaseAddress, &MemInfo[0], sizeof(MemInfo));
+        MEMORY_BASIC_INFORMATION MemInfo;
+
+        SIZE_T ret = VirtualQueryEx(hProcess, pBaseAddress, &MemInfo, sizeof(MemInfo));
         Assert(ret);
         if (!ret)
@@ -139,40 +139,33 @@
         }
 
-        unsigned cMemInfoBlocks = ret / sizeof(MemInfo[0]);
-
-        for (unsigned i = 0; i < cMemInfoBlocks; i++)
-        {
-            if (    MemInfo[i].State == MEM_COMMIT
-                &&  MemInfo[i].Type == MEM_IMAGE)
+        if (    MemInfo.State == MEM_COMMIT
+            &&  MemInfo.Type == MEM_IMAGE)
+        {
+            switch (MemInfo.Protect)
             {
-                switch (MemInfo[i].Protect)
-                {
-                case PAGE_EXECUTE:
-                case PAGE_EXECUTE_READ:
-                case PAGE_READONLY:
-                    aRegions[idxRegion].GCRegionAddr = (RTGCPTR64)MemInfo[i].BaseAddress;
-                    aRegions[idxRegion].cbRegion     = MemInfo[i].RegionSize;
-                    idxRegion++;
-                    break;
-
-                default:
-                    break; /* ignore */
-                }
+            case PAGE_EXECUTE:
+            case PAGE_EXECUTE_READ:
+            case PAGE_READONLY:
+                aRegions[idxRegion].GCRegionAddr = (RTGCPTR64)MemInfo.BaseAddress;
+                aRegions[idxRegion].cbRegion     = MemInfo.RegionSize;
+                idxRegion++;
+                break;
+
+            default:
+                break; /* ignore */
             }
-
-            pBaseAddress = (BYTE *)MemInfo[i].BaseAddress + MemInfo[i].RegionSize;
-            if (dwModuleSize > MemInfo[i].RegionSize)
-            {
-                dwModuleSize -= MemInfo[i].RegionSize;
-            }
-            else
-            {
-                dwModuleSize = 0;
-                break;
-            }
-
-            if (idxRegion >= RT_ELEMENTS(aRegions))
-                break;  /* out of room */
-        }
+        }
+
+        pBaseAddress = (BYTE *)MemInfo.BaseAddress + MemInfo.RegionSize;
+        if (dwModuleSize > MemInfo.RegionSize)
+        {
+            dwModuleSize -= MemInfo.RegionSize;
+        }
+        else
+        {
+            dwModuleSize = 0;
+            break;
+        }
+
         if (idxRegion >= RT_ELEMENTS(aRegions))
             break;  /* out of room */
