2816 Christopher Powers 2008-09-09
Bug#39350 Falcon: Releasing deferred indexes causes crash
Minor changes per code review
modified:
storage/falcon/Transaction.cpp
2815 Christopher Powers 2008-09-09
Bug#39350 Falcon: Releasing deferred indexes causes crash
- Transactions now bump the reference count for deferred indexes
- Transaction::releaseDeferredIndexes(Table *) now gets exclusive lock on
syncDeferredIndexes
modified:
storage/falcon/DeferredIndex.cpp
storage/falcon/DeferredIndexWalker.cpp
storage/falcon/StorageTableShare.cpp
storage/falcon/StorageTableShare.h
storage/falcon/Transaction.cpp
storage/falcon/Transaction.h
=== modified file 'storage/falcon/Transaction.cpp'
--- a/storage/falcon/Transaction.cpp 2008-09-10 04:02:07 +0000
+++ b/storage/falcon/Transaction.cpp 2008-09-10 04:37:47 +0000
@@ -1501,14 +1501,8 @@ void Transaction::releaseDeferredIndexes
for (DeferredIndex *deferredIndex; (deferredIndex = deferredIndexes);)
{
+ ASSERT(deferredIndex->transaction == this);
deferredIndexes = deferredIndex->nextInTransaction;
-
- if (deferredIndex->transaction)
- {
- ASSERT(deferredIndex->transaction == this);
- deferredIndex->detachTransaction();
- }
-
deferredIndex->releaseRef();
deferredIndexCount--;
}
@@ -1524,8 +1518,7 @@ void Transaction::releaseDeferredIndexes
if (deferredIndex->index && (deferredIndex->index->table == table))
{
*ptr = deferredIndex->nextInTransaction;
- if (deferredIndex->transaction)
- deferredIndex->detachTransaction();
+ deferredIndex->detachTransaction();
deferredIndex->releaseRef();
--deferredIndexCount;
}
| Thread |
|---|
| • bzr push into mysql-6.0-falcon branch (cpowers:2815 to 2816) Bug#39350 | Christopher Powers | 10 Sep |