Changeset 6831 in vbox
- Timestamp:
- Feb 6, 2008 3:16:36 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostServices/SharedFolders/vbsf.cpp
r6415 r6831 631 631 /* Open or create a file. */ 632 632 unsigned fOpen = 0; 633 bool fNoError = false; 634 633 635 int rc = vbsfConvertFileOpenFlags(pParms->CreateFlags, &fOpen); 634 636 if (RT_SUCCESS(rc)) … … 664 666 } 665 667 pParms->Result = SHFL_FILE_EXISTS; 668 669 /* This actually isn't an error, because the file simply already exists, 670 so correct the rc before return later, to make the driver (VBoxSF.sys) happy. */ 671 fNoError = true; 666 672 break; 667 673 default: … … 669 675 } 670 676 } 677 671 678 if (RT_SUCCESS(rc)) 672 679 { … … 738 745 pParms->Handle = handle; 739 746 } 747 748 /* Report the driver that all is okay, we're done here */ 749 if (fNoError) 750 rc = VINF_SUCCESS; 751 740 752 LogFlow(("vbsfOpenFile: rc = %Vrc\n", rc)); 741 753 return rc; … … 797 809 } 798 810 if ( RT_SUCCESS(rc) 799 || ( SHFL_CF_ACT_OPEN_IF_EXISTS800 == BIT_FLAG(pParms->CreateFlags, SHFL_CF_ACT_MASK_IF_EXISTS))) 811 || (SHFL_CF_ACT_OPEN_IF_EXISTS == BIT_FLAG(pParms->CreateFlags, SHFL_CF_ACT_MASK_IF_EXISTS)) 812 || (SHFL_FILE_EXISTS == pParms->Result)) /* Call of RTDirCreate() avbove failed, because already existing? */ 801 813 { 802 814 /* Open the directory now */
Note:
See TracChangeset
for help on using the changeset viewer.