aboutsummaryrefslogtreecommitdiff
path: root/src/common/DataStores/DB2Meta.cpp
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2020-06-27 13:33:17 +0200
committerShauren <shauren.trinity@gmail.com>2020-06-27 13:33:17 +0200
commitdeca201f7787f31187e2b9fab9cba7760313e786 (patch)
tree25c2b18ccd39760e2665a99c247980b606279e63 /src/common/DataStores/DB2Meta.cpp
parenteccc015ce7c9d54cb79e113706ef028cfc34b144 (diff)
Core/DataStores: Simplified string memory allocation in db2 files, dropped unneccessary level of indirection
Diffstat (limited to 'src/common/DataStores/DB2Meta.cpp')
-rw-r--r--src/common/DataStores/DB2Meta.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/common/DataStores/DB2Meta.cpp b/src/common/DataStores/DB2Meta.cpp
index b0e6a7f75e0..b08c67c37ef 100644
--- a/src/common/DataStores/DB2Meta.cpp
+++ b/src/common/DataStores/DB2Meta.cpp
@@ -16,6 +16,7 @@
*/
#include "DB2Meta.h"
+#include "Common.h"
#include "Errors.h"
DB2MetaField::DB2MetaField(DBCFormer type, uint8 arraySize, bool isSigned) : Type(type), ArraySize(arraySize), IsSigned(isSigned)
@@ -66,6 +67,8 @@ uint32 DB2Meta::GetRecordSize() const
size += 8;
break;
case FT_STRING:
+ size += sizeof(LocalizedString);
+ break;
case FT_STRING_NOT_LOCALIZED:
size += sizeof(char*);
break;
@@ -115,6 +118,8 @@ uint32 DB2Meta::GetIndexFieldOffset() const
offset += 8;
break;
case FT_STRING:
+ offset += sizeof(LocalizedString);
+ break;
case FT_STRING_NOT_LOCALIZED:
offset += sizeof(char*);
break;
@@ -157,6 +162,8 @@ int32 DB2Meta::GetParentIndexFieldOffset() const
offset += 8;
break;
case FT_STRING:
+ offset += sizeof(LocalizedString);
+ break;
case FT_STRING_NOT_LOCALIZED:
offset += sizeof(char*);
break;