Project

General

Profile

Actions

Bug #11334

closed

file: NULL pointer errors

Added by Toomas Soome about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
cmd - userland programs
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
External Bug:

Description

Build errors with NULL pointer:

    magicutils.c: In function 'f_mkmtab':
    magicutils.c:309:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       *p2++ = NULL;
             ^
    magicutils.c:323:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       *p2++ = NULL;
             ^
    magicutils.c:334:16: error: comparison between pointer and integer [-Werror]
         if (*(p+1) == NULL) {
                    ^~
    magicutils.c:337:23: error: comparison between pointer and integer [-Werror]
         } else if (*(p+2) == NULL) { /* d? */
                           ^~
    magicutils.c:382:16: error: comparison between pointer and integer [-Werror]
         if (*(p+1) == NULL) {
                    ^~
    magicutils.c:385:23: error: comparison between pointer and integer [-Werror]
         } else if (*(p+2) == NULL) { /* u? */
                           ^~
    magicutils.c:455:9: error: assignment makes integer from pointer without a cast [-Werror=int-conversion]
       *p2++ = NULL;
             ^

Actions #1

Updated by Electric Monk about 3 years ago

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

git commit 5521b7639b10e877e2e517a3498114aaf131b72d

commit  5521b7639b10e877e2e517a3498114aaf131b72d
Author: Toomas Soome <tsoome@me.com>
Date:   2019-07-11T15:06:20.000Z

    11334 file: NULL pointer errors
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Approved by: Dan McDonald <danmcd@joyent.com>

Actions

Also available in: Atom PDF