diff options
| author | liuli <liuli@uniontech.com> | 2025-05-30 13:53:02 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-05-30 07:53:02 +0200 |
| commit | 038e9511d1c35cfa3d6b25baae351ce78f58ef5d (patch) | |
| tree | bfd2b38fe57aeee3b644a21a16f4f68472b2784e | |
| parent | 94789d6705e636f8c23dadd31c9f83b670b4a1d9 (diff) | |
| download | box64-038e9511d1c35cfa3d6b25baae351ce78f58ef5d.tar.gz box64-038e9511d1c35cfa3d6b25baae351ce78f58ef5d.zip | |
fix: env BOX64_EMULATED_LIBS triggers sigsegv (#2686)
| -rw-r--r-- | src/tools/env.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/env.c b/src/tools/env.c index 7db6f015..08f823e9 100644 --- a/src/tools/env.c +++ b/src/tools/env.c @@ -188,7 +188,7 @@ static void applyCustomRules() snprintf(pathname, sizeof(pathname), "/tmp/perf-%d.map", getpid()); SET_BOX64ENV(dynarec_perf_map_fd, open(pathname, O_CREAT | O_RDWR | O_APPEND, S_IRUSR | S_IWUSR)); } - if (box64env.emulated_libs) { + if (box64env.emulated_libs && my_context) { AppendList(&my_context->box64_emulated_libs, box64env.emulated_libs, 0); } if (!box64env.libgl) { |