diff --git a/lib/std/os/uefi/protocol/device_path.zig b/lib/std/os/uefi/protocol/device_path.zig index 7ca2b942e1f12845a609839793f526992ed4c4c0..7fa8090df78cd208dd85ffb015bba0316570c74a 100644 --- 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;