@@ -117,19 +117,17 @@ void TKqpExecuterTxResult::FillYdb(Ydb::ResultSet* ydbResult, TMaybe<ui64> rowsL
117117
118118TTxAllocatorState::TTxAllocatorState (const IFunctionRegistry* functionRegistry,
119119 TIntrusivePtr<ITimeProvider> timeProvider, TIntrusivePtr<IRandomProvider> randomProvider)
120- : Alloc(__LOCATION__, NKikimr::TAlignedPagePoolCounters(), functionRegistry->SupportsSizedAllocators ())
121- , TypeEnv(Alloc)
120+ : Alloc(std::make_shared<NKikimr::NMiniKQL::TScopedAlloc>( __LOCATION__, NKikimr::TAlignedPagePoolCounters(), functionRegistry->SupportsSizedAllocators (), false ))
121+ , TypeEnv(* Alloc)
122122 , MemInfo(" TQueryData" )
123- , HolderFactory(Alloc. Ref(), MemInfo, functionRegistry)
123+ , HolderFactory(Alloc-> Ref (), MemInfo, functionRegistry)
124124{
125- Alloc.Release ();
126125 TimeProvider = timeProvider;
127126 RandomProvider = randomProvider;
128127}
129128
130129TTxAllocatorState::~TTxAllocatorState ()
131130{
132- Alloc.Acquire ();
133131}
134132
135133std::pair<NKikimr::NMiniKQL::TType*, NUdf::TUnboxedValue> TTxAllocatorState::GetInternalBindingValue (
@@ -366,7 +364,7 @@ const NKikimrMiniKQL::TParams* TQueryData::GetParameterMiniKqlValue(const TStrin
366364
367365 auto it = Params.find (name);
368366 if (it == Params.end ()) {
369- with_lock (AllocState->Alloc ) {
367+ with_lock (* AllocState->Alloc ) {
370368 const auto & [type, uv] = GetParameterUnboxedValue (name);
371369 NKikimrMiniKQL::TParams param;
372370 ExportTypeToProto (type, *param.MutableType ());
@@ -388,7 +386,7 @@ const Ydb::TypedValue* TQueryData::GetParameterTypedValue(const TString& name) {
388386
389387 auto it = ParamsProtobuf.find (name);
390388 if (it == ParamsProtobuf.end ()) {
391- with_lock (AllocState->Alloc ) {
389+ with_lock (* AllocState->Alloc ) {
392390 const auto & [type, uv] = GetParameterUnboxedValue (name);
393391
394392 auto & tv = ParamsProtobuf[name];
0 commit comments