- Timestamp:
- Nov 29, 2010 2:19:39 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManageGuestCtrl.cpp
r34406 r34465 1179 1179 RTListForEach(&listToCopy, pNode, DIRECTORYENTRY, Node) 1180 1180 { 1181 char *pszDestPath = RTStrDup(pNode->pszDestPath); 1182 AssertPtrBreak(pszDestPath); 1183 RTPathStripFilename(pszDestPath); 1184 1181 1185 if (fVerbose) 1182 #ifndef DEBUG 1183 RTPrintf("Copying \"%s\" (%u/%u) ...\n", 1184 pNode->pszSourcePath, uCurObject, cObjects); 1185 #else 1186 RTPrintf("Copying \"%s\" to \"%s\" (%u/%u) ...\n", 1187 pNode->pszSourcePath, pNode->pszDestPath, uCurObject, cObjects); 1188 #endif 1189 /* Finally copy the desired file (if no dry run selected). */ 1186 RTPrintf("Preparing guest directory \"%s\" ...\n", pszDestPath); 1187 1188 ComPtr<IProgress> progressDir; 1190 1189 if (!fDryRun) 1191 vrc = ctrlCopyFileToGuest(guest, pNode->pszSourcePath, pNode->pszDestPath, 1192 Utf8UserName.c_str(), Utf8Password.c_str(), uFlags); 1190 rc = guest->CreateDirectory(Bstr(pszDestPath).raw(), 1191 Bstr(Utf8UserName).raw(), Bstr(Utf8Password).raw(), 1192 0 /* Creation mode */, CreateDirectoryFlag_Parents, 1193 progressDir.asOutParam()); 1194 RTStrFree(pszDestPath); 1195 if (FAILED(rc)) 1196 vrc = ctrlPrintError(guest, COM_IIDOF(IGuest)); 1197 else 1198 { 1199 if (fVerbose) 1200 #ifndef DEBUG 1201 RTPrintf("Copying \"%s\" (%u/%u) ...\n", 1202 pNode->pszSourcePath, uCurObject, cObjects); 1203 #else 1204 RTPrintf("Copying \"%s\" to \"%s\" (%u/%u) ...\n", 1205 pNode->pszSourcePath, pNode->pszDestPath, uCurObject, cObjects); 1206 #endif 1207 /* Finally copy the desired file (if no dry run selected). */ 1208 if (!fDryRun) 1209 vrc = ctrlCopyFileToGuest(guest, pNode->pszSourcePath, pNode->pszDestPath, 1210 Utf8UserName.c_str(), Utf8Password.c_str(), uFlags); 1211 } 1193 1212 if (RT_FAILURE(vrc)) 1194 1213 break;
Note:
See TracChangeset
for help on using the changeset viewer.