diff options
| author | airp1ane <279825357+airp1ane@users.noreply.github.com> | 2026-11-22 13:53:36 -0500 |
|---|---|---|
| committer | airp1ane <279825357+airp1ane@users.noreply.github.com> | 2026-11-22 13:53:36 -0500 |
| commit | 5e3ec685a3a60e3f7597b96824b7ee52ba3396af (patch) | |
| tree | 6227c65185a815e23a1cd94b2dce67fbf91977f6 /runtime/src/main.cpp | |
| parent | 77444fa0fbbcfe99d56e44a89f21330b669ccc51 (diff) | |
pe_loader: a failed load, dependencies included, is not left findable by name
map_image records a module in by_name_ before mapping, binding and section
protection can throw. The run-time load path erased only the DLL it was
asked for, so a bundled dependency that failed while being bound stayed
registered with unbound imports, and a later LoadLibrary or GetModuleHandle
of it returned that half-loaded image. load() now erases its own key on any
failure; ~Loader still frees the mapping through order_.
loader_test: a parent imports fail_dep.dll, whose import table names a DLL
outside the image. After the failed load neither name is found and a second
load of either fails again (on the old code the dependency was still found).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'runtime/src/main.cpp')
0 files changed, 0 insertions, 0 deletions