diff options
Diffstat (limited to 'usr/src')
-rw-r--r-- | usr/src/common/smbios/smb_info.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr/src/common/smbios/smb_info.c b/usr/src/common/smbios/smb_info.c index b28413d6a5..eb39095bde 100644 --- a/usr/src/common/smbios/smb_info.c +++ b/usr/src/common/smbios/smb_info.c @@ -21,7 +21,7 @@ /* * Copyright 2015 OmniTI Computer Consulting, Inc. All rights reserved. - * Copyright (c) 2017, Joyent, Inc. + * Copyright (c) 2018, Joyent, Inc. * Copyright 2010 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -983,13 +983,15 @@ id_t smbios_info_boot(smbios_hdl_t *shp, smbios_boot_t *bp) { const smb_struct_t *stp = smb_lookup_type(shp, SMB_TYPE_BOOT); - const smb_boot_t *b = (smb_boot_t *)(uintptr_t)stp->smbst_hdr; + const smb_boot_t *b; if (stp == NULL) return (-1); /* errno is set for us */ bzero(bp, sizeof (smbios_boot_t)); + b = (smb_boot_t *)(uintptr_t)stp->smbst_hdr; + bp->smbt_status = b->smbbo_status[0]; bp->smbt_size = stp->smbst_hdr->smbh_len - sizeof (smb_boot_t); bp->smbt_data = bp->smbt_size ? &b->smbbo_status[1] : NULL; |