VirtualBox

Changeset 49683 in vbox for trunk/src


Ignore:
Timestamp:
Nov 27, 2013 3:42:13 PM (11 years ago)
Author:
vboxsync
Message:

FE/VBoxManage/GuestCtrl: Don't try to build up paths for the guest side when renaming.

File:
1 edited

Legend:

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

    r49621 r49683  
    14991499        fCloseSession = !fDetached;
    15001500
    1501         /* 
    1502          * If execution was aborted from the host side (signal handler), 
    1503          * close the guest session in any case. 
    1504          */ 
     1501        /*
     1502         * If execution was aborted from the host side (signal handler),
     1503         * close the guest session in any case.
     1504         */
    15051505        if (g_fGuestCtrlCanceled)
    15061506            fCloseSession = true;
     
    29502950        rc = pCtx->pGuestSession->DirectoryQueryInfo(Bstr(strDest).raw(), pFsObjInfo.asOutParam());
    29512951        if (FAILED(rc))
    2952             return RTMsgErrorExit(RTEXITCODE_FAILURE, "Destination must be a directory\n");
     2952            return RTMsgErrorExit(RTEXITCODE_FAILURE, "Destination must be a directory when speciying multiple sources\n");
    29532953    }
    29542954
     
    29842984            it++;
    29852985            continue; /* Skip. */
    2986         }
    2987 
    2988         if (!fSourceIsDirectory)
    2989         {
    2990             char *pszFileName = RTPathFilename(strCurSource.c_str());
    2991             if (!pszFileName)
    2992             {
    2993                 RTMsgError("Unable to extract file name from source \"%s\"",
    2994                            strCurSource.c_str());
    2995                 break;
    2996             }
    2997 
    2998             char szFileDest[RTPATH_MAX];
    2999             vrc = RTPathJoin(szFileDest, sizeof(szFileDest), strDest.c_str(), pszFileName);
    3000             if (RT_FAILURE(vrc))
    3001             {
    3002                 RTMsgError("Unable to build destination name for source \"%s\", rc=%Rrc",
    3003                            strCurSource.c_str(), vrc);
    3004                 break;
    3005             }
    3006 
    3007             strCurDest = szFileDest;
    30082986        }
    30092987
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