diff options
author | Toomas Soome <tsoome@me.com> | 2019-01-18 13:07:52 +0200 |
---|---|---|
committer | Toomas Soome <tsoome@me.com> | 2019-02-16 10:03:02 +0200 |
commit | 5c2def1fe977ee8010f1f89bb168ad7e84802013 (patch) | |
tree | 9debaee5f139f260f2babb264c70d8e4a38ea4fc | |
parent | 8f61ab7ac12fb355f5fddb909e48dc7b6f1c152b (diff) | |
download | illumos-joyent-5c2def1fe977ee8010f1f89bb168ad7e84802013.tar.gz |
10388 bofi: NULL pointer errors
Reviewed by: Andy Fiddaman <andy@omniosce.org>
Reviewed by: Andy Stormont <astormont@racktopsystems.com>
Reviewed by: Gergő Mihály Doma <domag02@gmail.com>
Approved by: Robert Mustacchi <rm@joyent.com>
-rw-r--r-- | usr/src/uts/common/io/bofi.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/src/uts/common/io/bofi.c b/usr/src/uts/common/io/bofi.c index 6554d29f76..dc52302851 100644 --- a/usr/src/uts/common/io/bofi.c +++ b/usr/src/uts/common/io/bofi.c @@ -625,7 +625,7 @@ bofi_attach(dev_info_t *dip, ddi_attach_cmd_t cmd) return (DDI_FAILURE); (void) snprintf(buf, sizeof (buf), "%s,ctl", name); if (ddi_create_minor_node(dip, buf, S_IFCHR, 0, - DDI_PSEUDO, NULL) == DDI_FAILURE) + DDI_PSEUDO, 0) == DDI_FAILURE) return (DDI_FAILURE); if (ddi_get_soft_iblock_cookie(dip, DDI_SOFTINT_MED, @@ -4478,7 +4478,7 @@ bofi_post_event(dev_info_t *dip, dev_info_t *rdip, for (lp = hp->link; lp != NULL; lp = lp->link) { ep = lp->errentp; ep->errstate.errmsg_count++; - if ((ep->errstate.msg_time == NULL || + if ((ep->errstate.msg_time == 0 || ep->errstate.severity > arg->f_impact) && (ep->state & BOFI_DEV_ACTIVE)) { ep->errstate.msg_time = bofi_gettime(); @@ -4535,7 +4535,7 @@ bofi_fm_ereport_callback(sysevent_t *ev, void *cookie) ep->errstate.errmsg_count++; if (!(ep->state & BOFI_DEV_ACTIVE)) continue; - if (ep->errstate.msg_time != NULL) + if (ep->errstate.msg_time != 0) continue; if (service_ereport) { ptr = class + strlen(service_class); |