about summary refs log tree commit diff stats
path: root/src/tools/env.c
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2025-09-03 18:29:46 +0200
committerptitSeb <sebastien.chev@gmail.com>2025-09-03 18:29:46 +0200
commit5e027587134a20451ab4aefde639eb254d80844a (patch)
tree98d8b388ffa0b80e68b61bdf09c6e59803314259 /src/tools/env.c
parentff9b2a235b0103217c1f3796cc524df26ad794ce (diff)
downloadbox64-5e027587134a20451ab4aefde639eb254d80844a.tar.gz
box64-5e027587134a20451ab4aefde639eb254d80844a.zip
Make sure to use custom allocator for everything Env related
Diffstat (limited to 'src/tools/env.c')
-rw-r--r--src/tools/env.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tools/env.c b/src/tools/env.c
index 25134089..c86a143c 100644
--- a/src/tools/env.c
+++ b/src/tools/env.c
@@ -12,6 +12,7 @@
 
 #include "os.h"
 #include "env.h"
+#include "custommem.h"
 #include "khash.h"
 #include "debug.h"
 #include "fileutils.h"
@@ -294,7 +295,7 @@ static void pushNewEntry(const char* name, box64env_t* env, int gen)
     k = kh_get(box64env_entry, khp, name);
     if (k == kh_end(khp)) {
         int ret;
-        k = kh_put(box64env_entry, khp, strdup(name), &ret);
+        k = kh_put(box64env_entry, khp, box_strdup(name), &ret);
     } else {
         freeEnv(&kh_value(khp, k));
     }