]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#4441] Fixed asan leak
authorThomas Markwalder <tmark@isc.org>
Fri, 17 Apr 2026 15:17:42 +0000 (11:17 -0400)
committerThomas Markwalder <tmark@isc.org>
Fri, 17 Apr 2026 17:21:44 +0000 (17:21 +0000)
modified:   src/lib/dhcpsrv/sflq_allocator.cc

src/lib/dhcpsrv/sflq_allocator.cc

index 3f842b805c29ccaf549de16722e6e26b3a8ef194..3116db99ee189421f688c74a85ec01b4b70d37aa 100644 (file)
@@ -100,7 +100,7 @@ SharedFlqAllocator::pickAddressInternal(const ClientClasses& client_classes,
     while (available.size()) {
         // Get a random pool from the available ones.
         auto offset = getRandomNumber(available.size() - 1);
-        auto const& pool = available[offset];
+        PoolPtr const pool = available[offset];
         switch (pool_type_) {
         case Lease::TYPE_V4: {
             // Ask the lease manager for a lease from the pool.
@@ -168,7 +168,7 @@ SharedFlqAllocator::pickPrefixInternal(const ClientClasses& client_classes,
     while (available.size()) {
         // Get a random pool from the available ones.
         auto offset = getRandomNumber(available.size() - 1);
-        auto const& pool = available[offset];
+        PoolPtr const pool = available[offset];
         switch(pool_type_) {
         case Lease::TYPE_V4:
             isc_throw(Unexpected, "pickAddressInternal called for Lease::TYPE_V4");