From: David T. <dav...@us...> - 2004-01-03 00:47:24
|
Update of /cvsroot/wonder/Wonder/Common/Frameworks/ERExtensions/Sources/er/extensions In directory sc8-pr-cvs1:/tmp/cvs-serv32084 Modified Files: ERXObjectStoreCoordinatorPool.java Log Message: ec is locked before setting its shared ec Index: ERXObjectStoreCoordinatorPool.java =================================================================== RCS file: /cvsroot/wonder/Wonder/Common/Frameworks/ERExtensions/Sources/er/extensions/ERXObjectStoreCoordinatorPool.java,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** ERXObjectStoreCoordinatorPool.java 9 Nov 2003 21:17:46 -0000 1.6 --- ERXObjectStoreCoordinatorPool.java 3 Jan 2004 00:47:19 -0000 1.7 *************** *** 146,156 **** ObjectStoreCoordinator os = (ObjectStoreCoordinator)defaultPool.currentRootObjectStore(); EOEditingContext ec = _newEditingContext(os, validationEnabled); - EOSharedEditingContext sec = os.sharedEditingContext(); - ec.setSharedEditingContext(sec); - return ec; - } ! protected EOEditingContext _createEditingContext(EOObjectStore parent) { ! return new ERXEC(parent == null ? EOEditingContext.defaultParentObjectStore() : parent); } } --- 146,160 ---- ObjectStoreCoordinator os = (ObjectStoreCoordinator)defaultPool.currentRootObjectStore(); EOEditingContext ec = _newEditingContext(os, validationEnabled); ! if (useSharedEditingContext()) { ! EOSharedEditingContext sec = os.sharedEditingContext(); ! ec.lock(); ! try { ! ec.setSharedEditingContext(sec); ! } finally { ! ec.unlock(); ! } ! } ! return ec; } } |