Changeset 97446 in vbox for trunk/src/VBox/Main/src-client/GuestSessionImplTasks.cpp
- Timestamp:
- Nov 8, 2022 8:16:02 AM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 154451
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-client/GuestSessionImplTasks.cpp
r97438 r97446 355 355 LogFlowFunc(("strPath=%s, fMode=%RU32, fCreate=0x%x, fCanExist=%RTbool\n", strPath.c_str(), fMode, fCreate, fCanExist)); 356 356 357 LogRel (("Guest Control: Creating host directory '%s' ...\n", strPath.c_str()));357 LogRel2(("Guest Control: Creating host directory '%s' ...\n", strPath.c_str())); 358 358 359 359 int vrc = RTDirCreate(strPath.c_str(), fMode, fCreate); … … 590 590 if (RTTimeSpecCompare(&srcModificationTimeTS, &dstObjInfo.ModificationTime) <= 0) 591 591 { 592 LogRel (("Guest Control: Host file \"%s\" has same or newer modification date, skipping", strDst.c_str()));592 LogRel2(("Guest Control: Host file \"%s\" has same or newer modification date, skipping", strDst.c_str())); 593 593 fSkip = true; 594 594 } … … 642 642 } 643 643 644 LogRel (("Guest Control: Copying file '%s' from guest to '%s' on host ...\n", strSrc.c_str(), strDst.c_str()));644 LogRel2(("Guest Control: Copying file '%s' from guest to '%s' on host ...\n", strSrc.c_str(), strDst.c_str())); 645 645 646 646 LogFlowFunc(("vrc=%Rrc, dstFsType=%#x, pszDstFile=%s\n", vrc, dstObjInfo.Attr.fMode & RTFS_TYPE_MASK, strDst.c_str())); … … 851 851 if (RTTimeSpecCompare(&dstModificationTimeTS, &srcObjInfo.ModificationTime) <= 0) 852 852 { 853 LogRel (("Guest Control: Guest file \"%s\" has same or newer modification date, skipping",853 LogRel2(("Guest Control: Guest file \"%s\" has same or newer modification date, skipping", 854 854 strDst.c_str())); 855 855 fSkip = true; … … 898 898 if (RT_SUCCESS(vrc)) 899 899 { 900 LogRel (("Guest Control: Copying file '%s' from host to '%s' on guest ...\n", strSrc.c_str(), strDst.c_str()));900 LogRel2(("Guest Control: Copying file '%s' from host to '%s' on guest ...\n", strSrc.c_str(), strDst.c_str())); 901 901 902 902 RTVFSFILE hSrcFile; … … 1041 1041 } 1042 1042 1043 #ifdef DEBUG 1043 1044 /** 1044 1045 * Dumps a FsList to the debug log. … … 1046 1047 void FsList::DumpToLog(void) 1047 1048 { 1048 Log Rel(("strSrcRootAbs=%s, strDstRootAbs=%s\n", mSrcRootAbs.c_str(), mDstRootAbs.c_str()));1049 LogFlowFunc(("strSrcRootAbs=%s, strDstRootAbs=%s\n", mSrcRootAbs.c_str(), mDstRootAbs.c_str())); 1049 1050 1050 1051 FsEntries::iterator itEntry = mVecEntries.begin(); … … 1052 1053 { 1053 1054 FsEntry *pEntry = *itEntry; 1054 LogRel(("\t%s: strPath=%s (fMode %#x)\n", 1055 RTFS_IS_DIRECTORY(pEntry->fMode) ? "Dir" : "File", pEntry->strPath.c_str(), pEntry->fMode)); 1055 LogFlowFunc(("\tstrPath=%s (fMode %#x)\n", pEntry->strPath.c_str(), pEntry->fMode)); 1056 1056 ++itEntry; 1057 1057 } … … 1059 1059 LogFlowFuncLeave(); 1060 1060 } 1061 #endif /* DEBUG */ 1061 1062 1062 1063 /** … … 1083 1084 LogFlowFunc(("Entering '%s' (sub '%s')\n", strPathAbs.c_str(), strPathSub.c_str())); 1084 1085 1085 LogRel (("Guest Control: Handling directory '%s' on guest ...\n", strPathAbs.c_str()));1086 LogRel2(("Guest Control: Handling directory '%s' on guest ...\n", strPathAbs.c_str())); 1086 1087 1087 1088 GuestDirectoryOpenInfo dirOpenInfo; … … 1147 1148 } 1148 1149 1149 LogRel (("Guest Control: Directory '%s'\n", strEntry.c_str()));1150 LogRel2(("Guest Control: Directory '%s'\n", strEntry.c_str())); 1150 1151 1151 1152 if (!(mSourceSpec.fDirCopyFlags & DirectoryCopyFlag_Recursive)) … … 1163 1164 /** @todo Symlink handling from guest is not implemented yet. 1164 1165 * See IGuestSession::symlinkRead(). */ 1165 LogRel (("Guest Control: Warning: Symlink support on guest side not available, skipping '%s'",1166 LogRel2(("Guest Control: Warning: Symlink support on guest side not available, skipping '%s'", 1166 1167 strEntry.c_str())); 1167 1168 } … … 1171 1172 case FsObjType_File: 1172 1173 { 1173 LogRel (("Guest Control: File '%s'\n", strEntry.c_str()));1174 LogRel2(("Guest Control: File '%s'\n", strEntry.c_str())); 1174 1175 1175 1176 vrc = AddEntryFromGuest(strEntry, fsObjInfo->i_getData()); … … 1222 1223 LogFlowFunc(("Entering '%s' (sub '%s')\n", strPathAbs.c_str(), strPathSub.c_str())); 1223 1224 1224 LogRel (("Guest Control: Handling directory '%s' on host ...\n", strPathAbs.c_str()));1225 LogRel2(("Guest Control: Handling directory '%s' on host ...\n", strPathAbs.c_str())); 1225 1226 1226 1227 RTFSOBJINFO objInfo; … … 1262 1263 break; 1263 1264 1264 LogRel (("Guest Control: Directory '%s'\n", strEntry.c_str()));1265 LogRel2(("Guest Control: Directory '%s'\n", strEntry.c_str())); 1265 1266 1266 1267 if (!(mSourceSpec.fDirCopyFlags & DirectoryCopyFlag_Recursive)) … … 1273 1274 case RTFS_TYPE_FILE: 1274 1275 { 1275 LogRel (("Guest Control: File '%s'\n", strEntry.c_str()));1276 LogRel2(("Guest Control: File '%s'\n", strEntry.c_str())); 1276 1277 1277 1278 vrc = AddEntryFromHost(strEntry, &pDirEntry->Info); … … 1291 1292 if (RTFS_IS_DIRECTORY(objInfo.Attr.fMode)) 1292 1293 { 1293 LogRel (("Guest Control: Symbolic link '%s' -> '%s' (directory)\n",1294 LogRel2(("Guest Control: Symbolic link '%s' -> '%s' (directory)\n", 1294 1295 strEntryAbs.c_str(), pszPathReal)); 1295 1296 if (mSourceSpec.fDirCopyFlags & DirectoryCopyFlag_FollowLinks) … … 1298 1299 else if (RTFS_IS_FILE(objInfo.Attr.fMode)) 1299 1300 { 1300 LogRel (("Guest Control: Symbolic link '%s' -> '%s' (file)\n",1301 LogRel2(("Guest Control: Symbolic link '%s' -> '%s' (file)\n", 1301 1302 strEntryAbs.c_str(), pszPathReal)); 1302 1303 if (mSourceSpec.fFileCopyFlags & DirectoryCopyFlag_FollowLinks) … … 1308 1309 1309 1310 if (RT_FAILURE(vrc)) 1310 LogRel (("Guest Control: Unable to query symbolic link info for '%s', rc=%Rrc\n",1311 LogRel2(("Guest Control: Unable to query symbolic link info for '%s', rc=%Rrc\n", 1311 1312 pszPathReal, vrc)); 1312 1313 } 1313 1314 else 1314 1315 { 1315 LogRel (("Guest Control: Unable to resolve symlink for '%s', rc=%Rrc\n", strPathAbs.c_str(), vrc));1316 LogRel2(("Guest Control: Unable to resolve symlink for '%s', rc=%Rrc\n", strPathAbs.c_str(), vrc)); 1316 1317 if (vrc == VERR_FILE_NOT_FOUND) /* Broken symlink, skip. */ 1317 1318 vrc = VINF_SUCCESS; … … 1523 1524 1524 1525 default: 1525 LogRel (("Guest Control: Warning: Unknown guest file system type %#x for source \"%s\", skipping\n",1526 LogRel2(("Guest Control: Warning: Unknown guest file system type %#x for source \"%s\", skipping\n", 1526 1527 itSrc->enmType, strSrc.c_str())); 1527 1528 break; … … 1536 1537 break; 1537 1538 } 1538 1539 #ifdef DEBUG 1539 1540 pFsList->DumpToLog(); 1540 1541 #endif 1541 1542 mVecLists.push_back(pFsList); 1542 1543 } … … 1646 1647 if (pList->mSourceSpec.enmType == FsObjType_Directory) 1647 1648 { 1648 Log Rel(("Guest Control: Directory: fDstExists=%RTbool,fDirCopyFlags=%#x, fCopyIntoExisting=%RTbool, fFollowSymlinks=%RTbool\n",1649 fDstExists,pList->mSourceSpec.fDirCopyFlags, fCopyIntoExisting, fFollowSymlinks));1649 LogFlowFunc(("Directory: fDirCopyFlags=%#x, fCopyIntoExisting=%RTbool, fFollowSymlinks=%RTbool\n", 1650 pList->mSourceSpec.fDirCopyFlags, fCopyIntoExisting, fFollowSymlinks)); 1650 1651 1651 1652 if (fDstExists) … … 1774 1775 else if (pList->mSourceSpec.enmType == FsObjType_File) 1775 1776 { 1776 Log Rel(("Guest Control: File: fDstExists=%RTbool,fFileCopyFlags=%#x, fCopyIntoExisting=%RTbool, fFollowSymlinks=%RTbool\n",1777 fDstExists,pList->mSourceSpec.fFileCopyFlags, fCopyIntoExisting, fFollowSymlinks));1777 LogFlowFunc(("File: fFileCopyFlags=%#x, fCopyIntoExisting=%RTbool, fFollowSymlinks=%RTbool\n", 1778 pList->mSourceSpec.fFileCopyFlags, fCopyIntoExisting, fFollowSymlinks)); 1778 1779 1779 1780 if (fDstExists) … … 1966 1967 1967 1968 default: 1968 LogRel (("Guest Control: Warning: Unknown guest host system type %#x for source \"%s\", skipping\n",1969 LogRel2(("Guest Control: Warning: Unknown guest host system type %#x for source \"%s\", skipping\n", 1969 1970 itSrc->enmType, strSrc.c_str())); 1970 1971 break; … … 1979 1980 break; 1980 1981 } 1981 1982 #ifdef DEBUG 1982 1983 pFsList->DumpToLog(); 1983 1984 #endif 1984 1985 mVecLists.push_back(pFsList); 1985 1986 } … … 2221 2222 case RTFS_TYPE_DIRECTORY: 2222 2223 { 2223 LogRel (("Guest Control: Copying directory '%s' from host to '%s' on guest ...\n", strSrcAbs.c_str(), strDstAbs.c_str()));2224 LogRel2(("Guest Control: Copying directory '%s' from host to '%s' on guest ...\n", strSrcAbs.c_str(), strDstAbs.c_str())); 2224 2225 if (!pList->mSourceSpec.fDryRun) 2225 2226 vrc = directoryCreateOnGuest(strDstAbs, fDirMode, DirectoryCreateFlag_None, … … 2236 2237 2237 2238 default: 2238 LogRel (("Guest Control: Warning: Host file system type 0x%x for '%s' is not supported, skipping\n",2239 LogRel2(("Guest Control: Warning: Host file system type 0x%x for '%s' is not supported, skipping\n", 2239 2240 pEntry->fMode & RTFS_TYPE_MASK, strSrcAbs.c_str())); 2240 2241 break;
Note:
See TracChangeset
for help on using the changeset viewer.