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

Avoid const_cast.

This commit is contained in:
robocop 2008-04-22 11:28:16 +00:00
parent a3e8480380
commit cd2e3a1862

View File

@ -73,8 +73,9 @@ static bool texttype_default_init(texttype* tt,
}
// name comes from stack. Copy it.
tt->texttype_name = FB_NEW(*getDefaultMemoryPool()) ASCII[strlen(name) + 1];
strcpy(const_cast<ASCII*>(tt->texttype_name), name);
ASCII* p = FB_NEW(*getDefaultMemoryPool()) ASCII[strlen(name) + 1];
strcpy(p, name);
tt->texttype_name = p;
tt->texttype_version = TEXTTYPE_VERSION_1;
tt->texttype_country = CC_INTL;