bsd: Add missing null-pointer check.
Found by: Coverity scan.
This commit is contained in:
parent
49978c5c4f
commit
1e0d718371
1 changed files with 2 additions and 1 deletions
|
@ -234,7 +234,8 @@ grub_bsd_add_meta_ptr (grub_uint32_t type, void **ptr, grub_uint32_t len)
|
||||||
{
|
{
|
||||||
struct bsd_tag *p;
|
struct bsd_tag *p;
|
||||||
for (p = tags;
|
for (p = tags;
|
||||||
p->type != (FREEBSD_MODINFO_METADATA | FREEBSD_MODINFOMD_KERNEND);
|
p && p->type != (FREEBSD_MODINFO_METADATA
|
||||||
|
| FREEBSD_MODINFOMD_KERNEND);
|
||||||
p = p->next);
|
p = p->next);
|
||||||
|
|
||||||
if (p)
|
if (p)
|
||||||
|
|
Loading…
Reference in a new issue