Changeset 81460 in vbox for trunk/src/VBox/GuestHost/SharedClipboard/ClipboardDataObjectImpl-win.cpp
- Timestamp:
- Oct 22, 2019 7:36:15 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/GuestHost/SharedClipboard/ClipboardDataObjectImpl-win.cpp
r81438 r81460 265 265 { 266 266 SHCLLISTENTRY entryList; 267 rc = ShClTransferList Read(pTransfer, hList,&entryList);267 rc = ShClTransferListEntryInit(&entryList); 268 268 if (RT_SUCCESS(rc)) 269 269 { 270 PSHCLFSOBJINFO pFsObjInfo = (PSHCLFSOBJINFO)entryList.pvInfo; 271 Assert(entryList.cbInfo == sizeof(SHCLFSOBJINFO)); 272 273 Utf8Str strPath = strDir + Utf8Str("\\") + Utf8Str(entryList.pszName); 274 275 LogFlowFunc(("\t%s (%RU64 bytes) -> %s\n", 276 entryList.pszName, pFsObjInfo->cbObject, strPath.c_str())); 277 278 if (RTFS_IS_DIRECTORY(pFsObjInfo->Attr.fMode)) 270 rc = ShClTransferListRead(pTransfer, hList, &entryList); 271 if (RT_SUCCESS(rc)) 279 272 { 280 /* Note: Directories are *not* required to be part of m_lstEntries, as we only 281 * count files to transfer there. */ 282 283 rc = readDir(pTransfer, strPath.c_str()); 273 if (ShClTransferListEntryIsValid(&entryList)) 274 { 275 PSHCLFSOBJINFO pFsObjInfo = (PSHCLFSOBJINFO)entryList.pvInfo; 276 Assert(entryList.cbInfo == sizeof(SHCLFSOBJINFO)); 277 278 Utf8Str strPath = strDir + Utf8Str("\\") + Utf8Str(entryList.pszName); 279 280 LogFlowFunc(("\t%s (%RU64 bytes) -> %s\n", 281 entryList.pszName, pFsObjInfo->cbObject, strPath.c_str())); 282 283 if (RTFS_IS_DIRECTORY(pFsObjInfo->Attr.fMode)) 284 { 285 FSOBJENTRY objEntry = { strPath.c_str(), *pFsObjInfo }; 286 287 m_lstEntries.push_back(objEntry); /** @todo Can this throw? */ 288 289 rc = readDir(pTransfer, strPath.c_str()); 290 } 291 else if (RTFS_IS_FILE(pFsObjInfo->Attr.fMode)) 292 { 293 FSOBJENTRY objEntry = { strPath.c_str(), *pFsObjInfo }; 294 295 m_lstEntries.push_back(objEntry); /** @todo Can this throw? */ 296 } 297 else 298 rc = VERR_NOT_SUPPORTED; 299 300 /** @todo Handle symlinks. */ 301 } 302 else 303 rc = VERR_INVALID_PARAMETER; 284 304 } 285 else if (RTFS_IS_FILE(pFsObjInfo->Attr.fMode)) 286 { 287 FSOBJENTRY objEntry = { strPath.c_str(), *pFsObjInfo }; 288 289 m_lstEntries.push_back(objEntry); /** @todo Can this throw? */ 290 } 291 292 /** @todo Handle symlinks. */ 305 306 ShClTransferListEntryDestroy(&entryList); 293 307 } 294 308 … … 359 373 if (RTFS_IS_DIRECTORY(pFsObjInfo->Attr.fMode)) 360 374 { 361 /* Note: Directories are *not* required to be part of m_lstEntries, as we only 362 * count files to transfer there. */ 375 FSOBJENTRY objEntry = { pRootEntry->pszName, *pFsObjInfo }; 376 377 pThis->m_lstEntries.push_back(objEntry); /** @todo Can this throw? */ 363 378 364 379 rc = pThis->readDir(pTransfer, pRootEntry->pszName); … … 370 385 pThis->m_lstEntries.push_back(objEntry); /** @todo Can this throw? */ 371 386 } 387 else 388 rc = VERR_NOT_SUPPORTED; 372 389 373 390 if (ASMAtomicReadBool(&pTransfer->Thread.fStop))
Note:
See TracChangeset
for help on using the changeset viewer.