Changeset 7992 in vbox for trunk/src/VBox/Main/ParallelPortImpl.cpp
- Timestamp:
- Apr 15, 2008 1:53:12 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ParallelPortImpl.cpp
r6168 r7992 163 163 * Loads settings from the given port node. 164 164 * May be called once right after this object creation. 165 * 165 * 166 166 * @param aPortNode <Port> node. 167 * 167 * 168 168 * @note Locks this object for writing. 169 169 */ … … 188 188 * place when a setting of a newly created object must default to A while 189 189 * the same setting of an object loaded from the old settings file must 190 * default to B. */ 190 * default to B. */ 191 191 192 192 /* enabled (required) */ … … 206 206 } 207 207 208 /** 208 /** 209 209 * Saves settings to the given port node. 210 * 210 * 211 211 * Note that the given Port node is comletely empty on input. 212 212 * 213 213 * @param aPortNode <Port> node. 214 * 215 * @note Locks this object for reading. 214 * 215 * @note Locks this object for reading. 216 216 */ 217 217 HRESULT ParallelPort::saveSettings (settings::Key &aPortNode) … … 272 272 273 273 /* sanity too */ 274 AutoCaller thatCaller (mPeer); 275 AssertComRCReturnVoid (thatCaller.rc()); 276 277 /* lock both for writing since we modify both */ 278 AutoMultiLock <2> alock (this->wlock(), AutoLock::maybeWlock (mPeer)); 274 AutoCaller peerCaller (mPeer); 275 AssertComRCReturnVoid (peerCaller.rc()); 276 277 /* lock both for writing since we modify both (mPeer is "master" so locked 278 * first) */ 279 AutoMultiWriteLock2 alock (mPeer, this); 279 280 280 281 if (mData.isBackedUp()) … … 302 303 303 304 /* sanity too */ 304 AutoCaller thatCaller ( mPeer);305 AutoCaller thatCaller (aThat); 305 306 AssertComRCReturnVoid (thatCaller.rc()); 306 307 307 /* peer is not modified, lock it for reading */ 308 AutoMultiLock <2> alock (this->wlock(), aThat->rlock()); 308 /* peer is not modified, lock it for reading (aThat is "master" so locked 309 * first) */ 310 AutoMultiLock2 alock (aThat->rlock(), this->wlock()); 309 311 310 312 /* this will back up current data */ … … 504 506 } 505 507 506 /** 508 /** 507 509 * Validates COMSETTER(Path) arguments. 508 510 */
Note:
See TracChangeset
for help on using the changeset viewer.