summaryrefslogtreecommitdiff
path: root/storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp
diff options
context:
space:
mode:
authorunknown <jonas@perch.ndb.mysql.com>2006-12-08 16:15:59 +0100
committerunknown <jonas@perch.ndb.mysql.com>2006-12-08 16:15:59 +0100
commiteff21a028df572a10b88a84c1ed12064de336573 (patch)
treefbf467577800d4e5916b12bbea75e69a53e22332 /storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp
parent3806777d8b290c73ac1109ed55d9e4200bc14c36 (diff)
downloadmariadb-git-eff21a028df572a10b88a84c1ed12064de336573.tar.gz
ndb - bug#24914
Fix start transaction with hint from ndbapi storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp: Fix fragments array for API storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp: Fix fragments array for API storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp: Fix fragments array for API
Diffstat (limited to 'storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp')
-rw-r--r--storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp b/storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp
index 40eb815d48b..4f6673cb468 100644
--- a/storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp
+++ b/storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp
@@ -2191,9 +2191,14 @@ NdbDictInterface::parseTableInfo(NdbTableImpl ** ret,
impl->m_replicaCount = replicaCount;
impl->m_fragmentCount = fragCount;
DBUG_PRINT("info", ("replicaCount=%x , fragCount=%x",replicaCount,fragCount));
- for(i = 0; i < (Uint32) (fragCount*replicaCount); i++)
+ Uint32 pos = 2;
+ for(i = 0; i < (Uint32) fragCount;i++)
{
- impl->m_fragments.push_back(ntohs(tableDesc->ReplicaData[i+2]));
+ pos++; // skip logpart
+ for (Uint32 j = 0; j<(Uint32)replicaCount; j++)
+ {
+ impl->m_fragments.push_back(ntohs(tableDesc->ReplicaData[pos++]));
+ }
}
Uint32 topBit = (1 << 31);