| ... | @@ -608,7 +608,10 @@ pub fn flushModule(self: *MachO, arena: Allocator, tid: Zcu.PerThread.Id, prog_n | ... | @@ -608,7 +608,10 @@ pub fn flushModule(self: *MachO, arena: Allocator, tid: Zcu.PerThread.Id, prog_n |
| 608 | else => |e| return diags.fail("failed to write code signature: {s}", .{@errorName(e)}), | 608 | else => |e| return diags.fail("failed to write code signature: {s}", .{@errorName(e)}), |
| 609 | }; | 609 | }; |
| 610 | const emit = self.base.emit; | 610 | const emit = self.base.emit; |
| 611 | try invalidateKernelCache(emit.root_dir.handle, emit.sub_path); | 611 | invalidateKernelCache(emit.root_dir.handle, emit.sub_path) catch |err| switch (err) { |
| | 612 | error.OutOfMemory => return error.OutOfMemory, |
| | 613 | else => |e| return diags.fail("failed to invalidate kernel cache: {s}", .{@errorName(e)}), |
| | 614 | }; |
| 612 | } | 615 | } |
| 613 | } | 616 | } |
| 614 | | 617 | |