Project

General

Profile

Bug #10871

st: comparison between pointer and integer

Added by Toomas Soome 7 months ago. Updated 6 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
driver - device drivers
Start date:
2019-04-28
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Debug build errors with NULL pointer:

    In file included from ../../common/sys/model.h:35:0,
                     from ../../common/sys/resource.h:221,
                     from ../../common/sys/user.h:73,
                     from ../../common/sys/proc.h:36,
                     from ../../common/sys/systm.h:40,
                     from ../../common/sys/scsi/scsi_types.h:56,
                     from ../../common/sys/scsi/scsi.h:36,
                     from ../../common/io/scsi/targets/st.c:36:
    ../../common/io/scsi/targets/st.c: In function 'st_doattach':
    ../../common/io/scsi/targets/st.c:1671:33: error: comparison between pointer and
     integer [-Werror]
      ASSERT(geterror(un->un_rqs_bp) == NULL);
                                     ^
    ../../common/sys/debug.h:59:29: note: in definition of macro 'ASSERT'
     #define ASSERT(EX) ((void)((EX) || assfail(#EX, __FILE__, __LINE__)))
                                 ^~
    cc1: all warnings being treated as errors

History

#1

Updated by Electric Monk 6 months ago

  • % Done changed from 90 to 100
  • Status changed from In Progress to Closed

git commit 0dcef4d473c5c7a38a378de19d7cb1b3a6a9bf6e

commit  0dcef4d473c5c7a38a378de19d7cb1b3a6a9bf6e
Author: Toomas Soome <tsoome@me.com>
Date:   2019-05-16T19:17:51.000Z

    10871 st: comparison between pointer and integer
    Reviewed by: Rob Johnston <rob.johnston@joyent.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF