VirtualBox

Changeset 105018 in vbox for trunk/src/VBox/Main/src-all


Ignore:
Timestamp:
Jun 25, 2024 11:06:29 AM (10 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
163636
Message:

doc/manual,include/VBox,Frontends/VBoxManage,HostServices/SharedFolders,
Main/{include,SharedFolder,Console,Machine,VirtualBox.xidl}: Backout
changeset r163634 since it introduces a build dependency on
VirtualBox_XPCOM.h which needs to be built from the VirtualBox.xidl
changes before it can be referenced by the src/VBox/HostServices code.
Need to putback the changes in two parts. bugref:10619

Location:
trunk/src/VBox/Main/src-all
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-all/ConsoleSharedFolderImpl.cpp

    r105016 r105018  
    4444    Data()
    4545    : fWritable(false),
    46       fAutoMount(false),
    47       enmSymlinkPolicy(SymlinkPolicy_None)
     46      fAutoMount(false)
    4847    { }
    4948
     
    5453    const Utf8Str   strAutoMountPoint;
    5554    Utf8Str         strLastAccessError;
    56     SymlinkPolicy_T enmSymlinkPolicy;
    5755};
    5856
     
    307305}
    308306
    309 HRESULT ConsoleSharedFolder::getSymlinkPolicy(SymlinkPolicy_T *aSymlinkPolicy)
    310 {
    311     AutoReadLock alock(this COMMA_LOCKVAL_SRC_POS);
    312     *aSymlinkPolicy = m->enmSymlinkPolicy;
    313     return S_OK;
    314 }
    315 
    316 HRESULT ConsoleSharedFolder::setSymlinkPolicy(SymlinkPolicy_T aSymlinkPolicy)
    317 {
    318     RT_NOREF(aSymlinkPolicy);
    319     return E_NOTIMPL;
    320 }
    321307
    322308const Utf8Str& ConsoleSharedFolder::i_getName() const
     
    345331}
    346332
    347 const SymlinkPolicy_T ConsoleSharedFolder::i_getSymlinkPolicy() const
    348 {
    349     return m->enmSymlinkPolicy;
    350 }
    351 
    352333/* vi: set tabstop=4 shiftwidth=4 expandtab: */
  • trunk/src/VBox/Main/src-all/SharedFolderImpl.cpp

    r105016 r105018  
    4646    Data()
    4747    : fWritable(false),
    48       fAutoMount(false),
    49       enmSymlinkPolicy(SymlinkPolicy_None)
     48      fAutoMount(false)
    5049    { }
    5150
     
    5655    const Utf8Str   strAutoMountPoint;
    5756    Utf8Str         strLastAccessError;
    58     SymlinkPolicy_T enmSymlinkPolicy;
    5957};
    6058
     
    111109                           bool aAutoMount,
    112110                           const Utf8Str &aAutoMountPoint,
    113                            bool fFailOnError,
    114                            SymlinkPolicy_T enmSymlinkPolicy)
     111                           bool fFailOnError)
    115112{
    116113    /* Enclose the state transition NotReady->InInit->Ready */
     
    120117    unconst(mMachine) = aMachine;
    121118
    122     HRESULT hrc = i_protectedInit(aMachine, aName, aHostPath, aWritable, aAutoMount, aAutoMountPoint, fFailOnError,
    123                                   enmSymlinkPolicy);
     119    HRESULT hrc = i_protectedInit(aMachine, aName, aHostPath, aWritable, aAutoMount, aAutoMountPoint, fFailOnError);
    124120
    125121    /* Confirm a successful initialization when it's the case */
     
    156152                                  aThat->m->fAutoMount,
    157153                                  aThat->m->strAutoMountPoint,
    158                                   false /* fFailOnError */,
    159                                   aThat->m->enmSymlinkPolicy);
     154                                  false /* fFailOnError */ );
    160155
    161156    /* Confirm a successful initialization when it's the case */
     
    219214                                      bool aAutoMount,
    220215                                      const Utf8Str &aAutoMountPoint,
    221                                       bool fFailOnError,
    222                                       SymlinkPolicy_T enmSymlinkPolicy)
    223 {
    224     LogFlowThisFunc(("aName={%s}, aHostPath={%s}, aWritable={%d}, aAutoMount={%d} enmSymlinkPolicy={%d}\n",
    225                       aName.c_str(), aHostPath.c_str(), aWritable, aAutoMount, enmSymlinkPolicy));
     216                                      bool fFailOnError)
     217{
     218    LogFlowThisFunc(("aName={%s}, aHostPath={%s}, aWritable={%d}, aAutoMount={%d}\n",
     219                      aName.c_str(), aHostPath.c_str(), aWritable, aAutoMount));
    226220
    227221    ComAssertRet(aParent && aName.isNotEmpty() && aHostPath.isNotEmpty(), E_INVALIDARG);
     
    277271    m->fAutoMount = aAutoMount;
    278272    unconst(m->strAutoMountPoint) = aAutoMountPoint;
    279     m->enmSymlinkPolicy = enmSymlinkPolicy;
    280273
    281274    return S_OK;
     
    392385}
    393386
    394 HRESULT SharedFolder::getSymlinkPolicy(SymlinkPolicy_T *aSymlinkPolicy)
    395 {
    396     AutoReadLock alock(this COMMA_LOCKVAL_SRC_POS);
    397     *aSymlinkPolicy = m->enmSymlinkPolicy;
    398     return S_OK;
    399 }
    400 
    401 HRESULT SharedFolder::setSymlinkPolicy(SymlinkPolicy_T aSymlinkPolicy)
    402 {
    403     switch (aSymlinkPolicy)
    404     {
    405         case SymlinkPolicy_AllowedToAnyTarget:
    406         case SymlinkPolicy_AllowedInShareSubtree:
    407         case SymlinkPolicy_AllowedToRelativeTargets:
    408         case SymlinkPolicy_Forbidden:
    409             break;
    410         default:
    411             return setError(E_INVALIDARG, tr("The symbolic link policy specified (%d) is invalid."), aSymlinkPolicy);
    412     }
    413 
    414     AutoWriteLock alock(this COMMA_LOCKVAL_SRC_POS);
    415     m->enmSymlinkPolicy = aSymlinkPolicy;
    416     return S_OK;
    417 }
    418387
    419388const Utf8Str& SharedFolder::i_getName() const
     
    442411}
    443412
    444 const SymlinkPolicy_T SharedFolder::i_getSymlinkPolicy() const
    445 {
    446     return m->enmSymlinkPolicy;
    447 }
    448 
    449413/* vi: set tabstop=4 shiftwidth=4 expandtab: */
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette