VirtualBox

Changeset 23381 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Sep 28, 2009 2:01:25 PM (15 years ago)
Author:
vboxsync
Message:

Main/ConsoleImpl2.cpp: preincrement optimization

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/ConsoleImpl2.cpp

    r23223 r23381  
    624624    /* Custom VESA mode list */
    625625    unsigned cModes = 0;
    626     for (unsigned iMode = 1; iMode <= 16; iMode++)
     626    for (unsigned iMode = 1; iMode <= 16; ++iMode)
    627627    {
    628628        char szExtraDataKey[sizeof("CustomVideoModeXX")];
     
    633633        rc = CFGMR3InsertStringW(pCfg, szExtraDataKey, str);                        RC_CHECK();
    634634        STR_FREE();
    635         cModes++;
     635        ++cModes;
    636636    }
    637637    STR_FREE();
     
    744744                }
    745745
    746                 for (uint32_t j = 0; j < 4; j++)
     746                for (uint32_t j = 0; j < 4; ++j)
    747747                {
    748748                    static const char *s_apszConfig[4] =
     
    10241024    rc = CFGMR3InsertNode(pDevices, "virtio-net", &pDevVirtioNet);                  RC_CHECK();
    10251025#endif /* VBOX_WITH_VIRTIO */
    1026     for (ULONG ulInstance = 0; ulInstance < SchemaDefs::NetworkAdapterCount; ulInstance++)
     1026    for (ULONG ulInstance = 0; ulInstance < SchemaDefs::NetworkAdapterCount; ++ulInstance)
    10271027    {
    10281028        ComPtr<INetworkAdapter> networkAdapter;
     
    11381138        memset(&Mac, 0, sizeof(Mac));
    11391139        char *pMac = (char*)&Mac;
    1140         for (uint32_t i = 0; i < 6; i++)
     1140        for (uint32_t i = 0; i < 6; ++i)
    11411141        {
    11421142            char c1 = *macStr++ - '0';
     
    11831183     */
    11841184    rc = CFGMR3InsertNode(pDevices, "serial", &pDev);                               RC_CHECK();
    1185     for (ULONG ulInstance = 0; ulInstance < SchemaDefs::SerialPortCount; ulInstance++)
     1185    for (ULONG ulInstance = 0; ulInstance < SchemaDefs::SerialPortCount; ++ulInstance)
    11861186    {
    11871187        ComPtr<ISerialPort> serialPort;
     
    12411241     */
    12421242    rc = CFGMR3InsertNode(pDevices, "parallel", &pDev);                             RC_CHECK();
    1243     for (ULONG ulInstance = 0; ulInstance < SchemaDefs::ParallelPortCount; ulInstance++)
     1243    for (ULONG ulInstance = 0; ulInstance < SchemaDefs::ParallelPortCount; ++ulInstance)
    12441244    {
    12451245        ComPtr<IParallelPort> parallelPort;
     
    17021702               offically like this but wtf) */
    17031703            *(char*)pszCFGMValueName = '\0';
    1704             pszCFGMValueName++;
     1704            ++pszCFGMValueName;
    17051705
    17061706            /* does the node already exist? */
     
    18521852        }
    18531853
    1854         for (ULONG pos = 1; pos <= SchemaDefs::MaxBootPosition; pos ++)
     1854        for (ULONG pos = 1; pos <= SchemaDefs::MaxBootPosition; ++pos)
    18551855        {
    18561856            hrc = pMachine->GetBootOrder(pos, &bootDevice);                             H();
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette