@@ -170,8 +170,8 @@ struct impure_value
170170 void make_decimal_fixed (const Firebird::Int128 val, const signed char scale);
171171
172172 template <class T >
173- VaryingString* getAllocateString (T requeuedLength, MemoryPool& pool) = delete; // Prevent dangerous length shrink
174- VaryingString* getAllocateString (USHORT requeuedLength, MemoryPool& pool);
173+ VaryingString* getString ( MemoryPool& pool, const T length ) = delete; // Prevent dangerous length shrink
174+ VaryingString* getString ( MemoryPool& pool, const USHORT length );
175175
176176 void makeImpureDscAddress (MemoryPool& pool);
177177 void allocateTextImpureDscAddress (MemoryPool& pool);
@@ -228,18 +228,18 @@ inline void impure_value::make_decimal_fixed(const Firebird::Int128 val, const s
228228 this ->vlu_desc .dsc_address = reinterpret_cast <UCHAR*>(&this ->vlu_misc .vlu_int128 );
229229}
230230
231- inline VaryingString* impure_value::getAllocateString (USHORT requeuedLength, MemoryPool& pool)
231+ inline VaryingString* impure_value::getString ( MemoryPool& pool, const USHORT length )
232232{
233- if (vlu_string && vlu_string->str_length < requeuedLength )
233+ if (vlu_string && vlu_string->str_length < length )
234234 {
235235 delete vlu_string;
236236 vlu_string = nullptr ;
237237 }
238238
239239 if (!vlu_string)
240240 {
241- vlu_string = FB_NEW_RPT (pool, requeuedLength ) VaryingString ();
242- vlu_string->str_length = requeuedLength ;
241+ vlu_string = FB_NEW_RPT (pool, length ) VaryingString ();
242+ vlu_string->str_length = length ;
243243 }
244244
245245 return vlu_string;
@@ -258,7 +258,7 @@ inline void impure_value::makeImpureDscAddress(MemoryPool& pool)
258258
259259inline void impure_value::allocateTextImpureDscAddress (MemoryPool& pool)
260260{
261- vlu_desc.dsc_address = getAllocateString ( vlu_desc.dsc_length , pool )->str_data ;
261+ vlu_desc.dsc_address = getString (pool, vlu_desc.dsc_length )->str_data ;
262262}
263263
264264
0 commit comments