Project

General

Profile

Bug #12433

efcode: NULL pointer errors

Added by Toomas Soome 9 months ago. Updated 8 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
lib - userland libraries
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

Build errors with NULL pointer on SPARC:

    ../pci.c: In function 'mem_map_in':
    ../pci.c:44: error: initialization makes integer from pointer without a cast
    ../pci.c:84: error: comparison between pointer and integer

    ../gp2.c: In function 'mem_map_in':
    ../gp2.c:41: error: initialization makes integer from pointer without a cast
    ../gp2.c:61: error: passing argument 3 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'uint64_t' but argument is of type 'void *'
    ../gp2.c:61: error: passing argument 4 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'size_t' but argument is of type 'void *'
    ../gp2.c:63: error: comparison between pointer and integer

    ../jupiter.c: In function 'mem_map_in':
    ../jupiter.c:53: error: initialization makes integer from pointer without a cast
    ../jupiter.c:73: error: passing argument 3 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'uint64_t' but argument is of type 'void *'
    ../jupiter.c:73: error: passing argument 4 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'size_t' but argument is of type 'void *'

    ../property.c: In function 'os_get_prop':
    ../property.c:132: error: comparison between pointer and integer

    ../build_tree.c: In function 'fc_nodeop':
    ../build_tree.c:50: error: return makes integer from pointer without a cast
    ../build_tree.c: In function 'get_prom_nodeid':
    ../build_tree.c:97: error: comparison between pointer and integer

    ../get_req.c: In function 'fc_get_request':
    ../get_req.c:82: error: comparison between pointer and integer
    ../get_req.c: In function 'get_efdaemon_request':
    ../get_req.c:356: error: comparison between pointer and integer

    ../memalloc.c: In function 'claim':
    ../memalloc.c:58: error: passing argument 3 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'uint64_t' but argument is of type 'void *'
    ../memalloc.c:58: error: passing argument 4 of 'mapping_to_mcookie' makes integer from pointer without a cast
    /code/illumos-gate/usr/src/lib/efcode/include/fcode/proto.h:426: note: expected 'size_t' but argument is of type 'void *'

    ../mcookie.c: In function 'add_map':
    ../mcookie.c:212: error: passing argument 3 of 'mapping_to_mcookie' makes integer from pointer without a cast
    ../mcookie.c:71: note: expected 'uint64_t' but argument is of type 'void *'
    ../mcookie.c:212: error: passing argument 4 of 'mapping_to_mcookie' makes integer from pointer without a cast
    ../mcookie.c:71: note: expected 'size_t' but argument is of type 'void *'

    ../env.c: In function 'validfmt':
    ../env.c:297: error: assignment makes integer from pointer without a cast
    ../env.c: In function 'fmt_args':
    ../env.c:438: error: comparison between pointer and integer
    ../env.c:491: error: comparison between pointer and integer

#1

Updated by Electric Monk 8 months ago

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

git commit 28e0ac9c914344194ef919b0271895d33f83d396

commit  28e0ac9c914344194ef919b0271895d33f83d396
Author: Toomas Soome <tsoome@me.com>
Date:   2020-04-07T17:44:10.000Z

    12433 efcode: NULL pointer errors
    Reviewed by: Gergő Doma <domag02@gmail.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF