commit 27e8d05ee8aa9e26b3fb925f841b228e082b45c2 (tree)
parent d2dda0737b72c9ce5c156050b2b8eb62b50bbf62
Author: jsentity <jsentity@noreply.codeberg.org>
Date: Sun, 18 Jan 2026 21:42:34 +0100
Fix protocol.DevicePath.next() (#30883)
fix for https://codeberg.org/ziglang/zig/issues/30882
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/30883
Reviewed-by: Andrew Kelley <andrew@ziglang.org>
Co-authored-by: jsentity <jsentity@noreply.codeberg.org>
Co-committed-by: jsentity <jsentity@noreply.codeberg.org>
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/std/os/uefi/protocol/device_path.zig b/lib/std/os/uefi/protocol/device_path.zig
@@ -28,7 +28,7 @@ pub const DevicePath = extern struct {
pub fn next(self: *const DevicePath) ?*const DevicePath {
const bytes: [*]const u8 = @ptrCast(self);
const next_node: *const DevicePath = @ptrCast(bytes + self.length);
- if (next_node.type == .end and @as(uefi.DevicePath.End.Subtype, @enumFromInt(self.subtype)) == .end_entire)
+ if (next_node.type == .end and @as(uefi.DevicePath.End.Subtype, @enumFromInt(next_node.subtype)) == .end_entire)
return null;
return next_node;