VirtualBox

Changeset 22487 in vbox


Ignore:
Timestamp:
Aug 26, 2009 8:55:09 PM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
51507
Message:

Main: Fixed a handful status code mixups caught by RTERR_STRICT_RC.

Location:
trunk/src/VBox/Main
Files:
3 edited

Legend:

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

    r22317 r22487  
    989989         * disk images in */
    990990        vrc = RTDirCreateTemp(pszTmpDir);
    991         if (RT_FAILURE(rc))
     991        if (RT_FAILURE(vrc))
    992992            throw setError(VBOX_E_FILE_ERROR,
    993993                           tr("Cannot create temporary directory '%s'"), pszTmpDir);
     
    18601860         * in */
    18611861        vrc = RTDirCreateTemp(pszTmpDir);
    1862         if (RT_FAILURE(rc))
     1862        if (RT_FAILURE(vrc))
    18631863            throw setError(VBOX_E_FILE_ERROR,
    18641864                           tr("Cannot create temporary directory '%s'"), pszTmpDir);
     
    29702970         * disk images in */
    29712971        vrc = RTDirCreateTemp(pszTmpDir);
    2972         if (RT_FAILURE(rc))
     2972        if (RT_FAILURE(vrc))
    29732973            throw setError(VBOX_E_FILE_ERROR,
    29742974                           tr("Cannot create temporary directory '%s'"), pszTmpDir);
  • trunk/src/VBox/Main/ConsoleImpl.cpp

    r22480 r22487  
    73297329        do
    73307330        {
    7331             LogFlowFunc (("Reattaching new differencing hard disks...\n"));
     7331            LogFlowFunc(("Reattaching new differencing hard disks...\n"));
    73327332
    73337333            com::SafeIfaceArray<IHardDiskAttachment> atts;
    7334             rc = that->mMachine->
    7335                 COMGETTER(HardDiskAttachments) (ComSafeArrayAsOutParam (atts));
     7334            rc = that->mMachine->COMGETTER(HardDiskAttachments)(ComSafeArrayAsOutParam(atts));
    73367335            if (FAILED (rc))
    73377336                break;
     
    73507349                 */
    73517350                rc = atts[i]->COMGETTER(Controller)(&controllerName);
    7352                 if (FAILED (rc))
     7351                if (FAILED(rc))
    73537352                    break;
    73547353
    73557354                rc = that->mMachine->GetStorageControllerByName(controllerName, controller.asOutParam());
    7356                 if (FAILED (rc))
     7355                if (FAILED(rc))
    73577356                    break;
    73587357
     
    73637362                 *  to access Console.
    73647363                 */
    7365                 int vrc = VMR3ReqCall (that->mpVM, VMCPUID_ANY, &pReq, RT_INDEFINITE_WAIT,
    7366                                        (PFNRT)reconfigureHardDisks, 5, that->mpVM, lInstance,
    7367                                        enmController, atts [i], &rc);
    7368                 if (VBOX_SUCCESS (rc))
    7369                     rc = pReq->iStatus;
    7370                 VMR3ReqFree (pReq);
    7371                 if (FAILED (rc))
    7372                     break;
    7373                 if (VBOX_FAILURE (vrc))
     7364                int vrc = VMR3ReqCall(that->mpVM, VMCPUID_ANY, &pReq, RT_INDEFINITE_WAIT,
     7365                                      (PFNRT)reconfigureHardDisks, 5, that->mpVM, lInstance, enmController, atts[i], &rc);
     7366                if (RT_SUCCESS(vrc))
     7367                    vrc = pReq->iStatus;
     7368                VMR3ReqFree(pReq);
     7369                if (RT_FAILURE(vrc))
    73747370                {
    7375                     errMsg = Utf8StrFmt (Console::tr ("%Rrc"), vrc);
     7371                    errMsg = Utf8StrFmt(Console::tr("%Rrc"), vrc);
    73767372                    rc = E_FAIL;
    73777373                    break;
    73787374                }
     7375                if (FAILED(rc))
     7376                    break;
    73797377            }
    73807378        }
  • trunk/src/VBox/Main/MachineImpl.cpp

    r22318 r22487  
    59295929        ULONG portCount;
    59305930        rc = pCtl->COMGETTER(PortCount)(&portCount);
    5931         ComAssertRCRet(rc, rc);
     5931        ComAssertComRCRet(rc, rc);
    59325932        ctl.ulPortCount = portCount;
    59335933
     
    59405940                 || (FAILED(rc = pCtl->GetIDEEmulationPort(3, (LONG*)&ctl.lIDE1SlaveEmulationPort)))
    59415941               )
    5942                 ComAssertRCRet(rc, rc);
     5942                ComAssertComRCRet(rc, rc);
    59435943        }
    59445944
    59455945        /* save the devices now. */
    59465946        rc = saveStorageDevices(pCtl, ctl);
    5947         ComAssertRCRet(rc, rc);
     5947        ComAssertComRCRet(rc, rc);
    59485948
    59495949        data.llStorageControllers.push_back(ctl);
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