diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2023-10-06 16:36:45 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-10-06 16:36:45 -0700 |
| commit | 41a4908dcc123818315ad26de90fd8d157268484 (patch) | |
| tree | 56d3fcab61d2abe4986834f6d7362c1dd93d1b74 /lib/std | |
| parent | 2d0ddce309cbc0cac8a91e7aed5b3cdb988c9fa8 (diff) | |
| parent | 91ef6d11734bd6976749aa373fa19a17f6ed85dd (diff) | |
| download | zig-41a4908dcc123818315ad26de90fd8d157268484.tar.gz zig-41a4908dcc123818315ad26de90fd8d157268484.zip | |
Merge pull request #17419 from ziglang/unsound-native-target-info
std: fix memory bug in getExternalExecutor
Diffstat (limited to 'lib/std')
| -rw-r--r-- | lib/std/Build/Step/Run.zig | 2 | ||||
| -rw-r--r-- | lib/std/zig/system/NativeTargetInfo.zig | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/Build/Step/Run.zig b/lib/std/Build/Step/Run.zig index 66e9224fe5..9d8f26559c 100644 --- a/lib/std/Build/Step/Run.zig +++ b/lib/std/Build/Step/Run.zig @@ -679,7 +679,7 @@ fn runCommand( } const need_cross_glibc = exe.target.isGnuLibC() and exe.is_linking_libc; - switch (b.host.getExternalExecutor(exe.target_info, .{ + switch (b.host.getExternalExecutor(&exe.target_info, .{ .qemu_fixes_dl = need_cross_glibc and b.glibc_runtimes_dir != null, .link_libc = exe.is_linking_libc, })) { diff --git a/lib/std/zig/system/NativeTargetInfo.zig b/lib/std/zig/system/NativeTargetInfo.zig index 6691e0f3cb..bcb60d968e 100644 --- a/lib/std/zig/system/NativeTargetInfo.zig +++ b/lib/std/zig/system/NativeTargetInfo.zig @@ -1002,7 +1002,7 @@ pub const GetExternalExecutorOptions = struct { /// of the other target. pub fn getExternalExecutor( host: NativeTargetInfo, - candidate: NativeTargetInfo, + candidate: *const NativeTargetInfo, options: GetExternalExecutorOptions, ) Executor { const os_match = host.target.os.tag == candidate.target.os.tag; |
