8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 23:23:04 +01:00

Fix possible problem with the transliteration buffer size - thanks to Claudio

This commit is contained in:
asfernandes 2009-12-06 13:51:03 +00:00
parent 6bd1c617a1
commit 43a6918fe3

View File

@ -166,7 +166,7 @@ string DdlNode::stringInUserCharSet(thread_db* tdbb, const string& str)
if (charSet == CS_METADATA || charSet == CS_NONE)
return str;
HalfStaticArray<UCHAR, BUFFER_MEDIUM> buffer(str.length());
HalfStaticArray<UCHAR, BUFFER_MEDIUM> buffer(str.length() * sizeof(ULONG));
ULONG len = INTL_convert_bytes(tdbb, charSet, buffer.begin(), buffer.getCapacity(),
CS_METADATA, (const BYTE*) str.c_str(), str.length(), ERR_post);