VirtualBox

Changeset 107886 in vbox for trunk/src


Ignore:
Timestamp:
Jan 22, 2025 10:55:54 AM (4 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
167100
Message:

Frontends/VBoxManage/VBoxManageMisc.cpp: Fixed warnings found by Parfait (unused assignment + unread variable). jiraref:VBP-1424

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxManage/VBoxManageMisc.cpp

    r106061 r107886  
    240240                        RTEXITCODE_FAILURE);
    241241
    242         hrc = showProgress(pProgress);
     242        showProgress(pProgress);
    243243        CHECK_PROGRESS_ERROR_RET(pProgress, (Misc::tr("Machine delete failed")), RTEXITCODE_FAILURE);
    244244    }
     
    253253            IMedium *pMedium = aMedia[i];
    254254            if (pMedium)
    255                 hrc = pMedium->Close();
    256         }
    257         hrc = S_OK; /** @todo r=andy Why overwriting the result from closing the medium above? */
     255                pMedium->Close();
     256        }
     257
     258        hrc = S_OK; /* See comment above, so just set success here. */
    258259    }
    259260    return RTEXITCODE_SUCCESS;
     
    547548                               progress.asOutParam()),
    548549                        RTEXITCODE_FAILURE);
    549         hrc = showProgress(progress);
     550        showProgress(progress);
    550551        CHECK_PROGRESS_ERROR_RET(progress, (Misc::tr("Move VM failed")), RTEXITCODE_FAILURE);
    551552
     
    759760                                        progress.asOutParam()),
    760761                    RTEXITCODE_FAILURE);
    761     hrc = showProgress(progress);
     762    showProgress(progress);
    762763    CHECK_PROGRESS_ERROR_RET(progress, (Misc::tr("Clone VM failed")), RTEXITCODE_FAILURE);
    763764
     
    20072008    RTGETOPTUNION   ValueUnion;
    20082009    int             ch;
    2009     HRESULT         hrc = S_OK;
    20102010
    20112011    if (!strcmp(a->argv[0], "install"))
     
    20962096        ComPtr<IProgress> ptrProgress;
    20972097        CHECK_ERROR2I_RET(ptrExtPackFile, Install(fReplace, NULL, ptrProgress.asOutParam()), RTEXITCODE_FAILURE);
    2098         hrc = showProgress(ptrProgress);
     2098        showProgress(ptrProgress);
    20992099        CHECK_PROGRESS_ERROR_RET(ptrProgress, (Misc::tr("Failed to install \"%s\""), szPath), RTEXITCODE_FAILURE);
    21002100
     
    21372137        ComPtr<IProgress> ptrProgress;
    21382138        CHECK_ERROR2I_RET(ptrExtPackMgr, Uninstall(bstrName.raw(), fForced, NULL, ptrProgress.asOutParam()), RTEXITCODE_FAILURE);
    2139         hrc = showProgress(ptrProgress);
     2139        showProgress(ptrProgress);
    21402140        CHECK_PROGRESS_ERROR_RET(ptrProgress, (Misc::tr("Failed to uninstall \"%s\""), pszName), RTEXITCODE_FAILURE);
    21412141
Note: See TracChangeset for help on using the changeset viewer.

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