mirror of
https://github.com/MariaDB/server.git
synced 2025-11-19 19:03:26 +03:00
Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-clean
This commit is contained in:
@@ -1526,6 +1526,7 @@ int NdbDictionaryImpl::alterTable(NdbTableImpl &impl)
|
||||
// If in local cache it must be in global
|
||||
if (!cachedImpl)
|
||||
abort();
|
||||
cachedImpl->m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(cachedImpl);
|
||||
m_globalHash->unlock();
|
||||
}
|
||||
@@ -1830,8 +1831,8 @@ NdbDictionaryImpl::dropTable(const char * name)
|
||||
|
||||
DBUG_PRINT("info",("INCOMPATIBLE_VERSION internal_name: %s", internalTableName));
|
||||
m_localHash.drop(internalTableName);
|
||||
|
||||
m_globalHash->lock();
|
||||
tab->m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(tab);
|
||||
m_globalHash->unlock();
|
||||
DBUG_RETURN(dropTable(name));
|
||||
@@ -1875,10 +1876,11 @@ NdbDictionaryImpl::dropTable(NdbTableImpl & impl)
|
||||
int ret = m_receiver.dropTable(impl);
|
||||
if(ret == 0 || m_error.code == 709){
|
||||
const char * internalTableName = impl.m_internalName.c_str();
|
||||
|
||||
|
||||
m_localHash.drop(internalTableName);
|
||||
|
||||
m_globalHash->lock();
|
||||
impl.m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(&impl);
|
||||
m_globalHash->unlock();
|
||||
|
||||
@@ -1976,6 +1978,7 @@ NdbDictionaryImpl::invalidateObject(NdbTableImpl & impl)
|
||||
|
||||
m_localHash.drop(internalTableName);
|
||||
m_globalHash->lock();
|
||||
impl.m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(&impl);
|
||||
m_globalHash->unlock();
|
||||
return 0;
|
||||
@@ -2242,8 +2245,8 @@ NdbDictionaryImpl::dropIndex(const char * indexName,
|
||||
m_ndb.internalizeTableName(indexName); // Index is also a table
|
||||
|
||||
m_localHash.drop(internalIndexName);
|
||||
|
||||
m_globalHash->lock();
|
||||
idx->m_table->m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(idx->m_table);
|
||||
m_globalHash->unlock();
|
||||
return dropIndex(indexName, tableName);
|
||||
@@ -2277,8 +2280,8 @@ NdbDictionaryImpl::dropIndex(NdbIndexImpl & impl, const char * tableName)
|
||||
int ret = m_receiver.dropIndex(impl, *timpl);
|
||||
if(ret == 0){
|
||||
m_localHash.drop(internalIndexName);
|
||||
|
||||
m_globalHash->lock();
|
||||
impl.m_table->m_status = NdbDictionary::Object::Invalid;
|
||||
m_globalHash->drop(impl.m_table);
|
||||
m_globalHash->unlock();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user