From cbfc0c772918b52d9b61a7b00e57b19f11972672 Mon Sep 17 00:00:00 2001
From: Lennart Poettering <lennart@poettering.net>
Date: Fri, 1 Mar 2024 21:43:21 +0100
Subject: [PATCH 0431/1160] hashmap: reorder fields to pack structure better

When building with ENABLE_DEBUG_HASHMAP we can pack the hashmap iterator
structure a bit better.

Fixes: #31558
(cherry picked from commit e28b70a52752a3da6d517982f33a9b1ee85f3f37)
---
 src/basic/hashmap.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/basic/hashmap.h b/src/basic/hashmap.h
index 233f1d7a1e..d0ebdf545e 100644
--- a/src/basic/hashmap.h
+++ b/src/basic/hashmap.h
@@ -39,8 +39,8 @@ typedef struct IteratedCache IteratedCache;   /* Caches the iterated order of on
  * by hashmap users, so the definition has to be here. Do not use its fields
  * directly. */
 typedef struct {
-        unsigned idx;         /* index of an entry to be iterated next */
         const void *next_key; /* expected value of that entry's key pointer */
+        unsigned idx;         /* index of an entry to be iterated next */
 #if ENABLE_DEBUG_HASHMAP
         unsigned put_count;   /* hashmap's put_count recorded at start of iteration */
         unsigned rem_count;   /* hashmap's rem_count in previous iteration */
-- 
2.33.0