diff options
author | Laszlo Ersek <lersek@redhat.com> | 2012-12-18 05:11:39 +0100 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2012-12-21 22:50:52 -0500 |
commit | 9c6fb72b852dbeea752caa05bbdc4236dbb08d40 (patch) | |
tree | 9299ab89a4fc5e57d7272cb38b67daec6106d7e8 | |
parent | a810e4e72a0d42c7bc04eda57382f8e019add901 (diff) | |
download | seabios-9c6fb72b852dbeea752caa05bbdc4236dbb08d40.zip seabios-9c6fb72b852dbeea752caa05bbdc4236dbb08d40.tar.gz seabios-9c6fb72b852dbeea752caa05bbdc4236dbb08d40.tar.bz2 |
display_uuid(): fix incomplete check after the loop
In the v2->v3 change of what would become commit 37676f83
<http://www.seabios.org/pipermail/seabios/2012-December/005166.html>, the
defense against an initial "addr > end" condition ("wraparound") was
erroneously loosened.
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
-rw-r--r-- | src/smbios.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/smbios.c b/src/smbios.c index aaa99bc..23713a2 100644 --- a/src/smbios.c +++ b/src/smbios.c @@ -569,8 +569,8 @@ display_uuid(void) addr += 2; } - /* parsing finished, UUID not found */ - if (addr == end) + /* parsing finished or skipped entirely, UUID not found */ + if (addr >= end) return; uuid = (u8 *)(addr + offsetof(struct smbios_type_1, uuid)); |