Changeset 13165 in vbox for trunk/src/VBox/Main/MachineImpl.cpp
- Timestamp:
- Oct 10, 2008 11:27:30 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/MachineImpl.cpp
r12914 r13165 8926 8926 LogFlowThisFunc (("\n")); 8927 8927 8928 #ifdef VBOX_WITH_GUEST_PROPS 8928 8929 AutoCaller autoCaller (this); 8929 8930 AssertComRCReturn (autoCaller.rc(), autoCaller.rc()); … … 8957 8958 mHWData->mPropertyServiceActive = true; 8958 8959 return S_OK; 8960 #else 8961 return VERR_NOT_IMPLEMENTED; 8962 #endif 8959 8963 } 8960 8964 … … 8965 8969 { 8966 8970 LogFlowThisFunc (("\n")); 8971 8972 #ifdef VBOX_WITH_GUEST_PROPS 8967 8973 AutoCaller autoCaller (this); 8968 8974 AssertComRCReturn (autoCaller.rc(), autoCaller.rc()); … … 9006 9012 mData->mRegistered = TRUE; 9007 9013 return S_OK; 9014 #else 9015 return VERR_NOT_IMPLEMENTED; 9016 #endif 9017 } 9018 9019 STDMETHODIMP SessionMachine::PushGuestProperty (INPTR BSTR aName, INPTR BSTR aValue, 9020 ULONG64 aTimestamp, INPTR BSTR aFlags) 9021 { 9022 LogFlowThisFunc (("\n")); 9023 9024 #ifdef VBOX_WITH_GUEST_PROPS 9025 if (!VALID_PTR(aName)) 9026 return E_INVALIDARG; 9027 if ((aValue != NULL) && (!VALID_PTR(aValue) || !VALID_PTR(aFlags))) 9028 return E_INVALIDARG; /* aValue can be NULL to indicate deletion */ 9029 9030 AutoCaller autoCaller (this); 9031 CheckComRCReturnRC (autoCaller.rc()); 9032 9033 AutoWriteLock alock (this); 9034 9035 HRESULT rc = checkStateDependency (MutableStateDep); 9036 CheckComRCReturnRC (rc); 9037 9038 mHWData.backup(); 9039 for (HWData::GuestPropertyList::iterator iter = mHWData->mGuestProperties.begin(); 9040 iter != mHWData->mGuestProperties.end(); ++iter) 9041 if (aName == iter->mName) 9042 { 9043 mHWData->mGuestProperties.erase(iter); 9044 break; 9045 } 9046 if (aValue != NULL) 9047 { 9048 HWData::GuestProperty property = { aName, aValue, aTimestamp, aFlags }; 9049 mHWData->mGuestProperties.push_back(property); 9050 } 9051 9052 /* send a callback notification if appropriate */ 9053 alock.leave(); 9054 // doGuestPropertyCallback(aName, aValue, aFlags); 9055 9056 return S_OK; 9057 #else 9058 return VERR_NOT_IMPLEMENTED; 9059 #endif 9008 9060 } 9009 9061
Note:
See TracChangeset
for help on using the changeset viewer.