VirtualBox

Ignore:
Timestamp:
Feb 20, 2009 9:14:28 AM (16 years ago)
Author:
vboxsync
Message:

#3551: “Main: Replace remaining collections with safe arrays”
Converted SharedFolderCollection. Approved by dmik. Tested with GUI.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/MachineImpl.cpp

    r16867 r16966  
    17541754
    17551755STDMETHODIMP
    1756 Machine::COMGETTER(SharedFolders) (ISharedFolderCollection **aSharedFolders)
    1757 {
    1758     CheckComArgOutPointerValid (aSharedFolders);
     1756Machine::COMGETTER(SharedFolders) (ComSafeArrayOut (ISharedFolder *, aSharedFolders))
     1757{
     1758    CheckComArgOutSafeArrayPointerValid (aSharedFolders);
    17591759
    17601760    AutoCaller autoCaller (this);
     
    17631763    AutoReadLock alock (this);
    17641764
    1765     ComObjPtr <SharedFolderCollection> coll;
    1766     coll.createObject();
    1767     coll->init (mHWData->mSharedFolders);
    1768     coll.queryInterfaceTo (aSharedFolders);
     1765    SafeIfaceArray <ISharedFolder> folders (mHWData->mSharedFolders);
     1766    folders.detachTo (ComSafeArrayOutArg(aSharedFolders));
    17691767
    17701768    return S_OK;
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