Project

General

Profile

Bug #10429

loader: dereferencing type-punned pointer will break strict-aliasing rules

Added by Toomas Soome 5 months ago. Updated 5 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
bootloader
Start date:
2019-02-20
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Build errors with -Wstrict-aliasing:

    In file included from isoboot.c:117:
    cd9660read.c: In function 'cd9660_lookup':
    cd9660read.c:248: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]

    bootinfo32.c: In function 'bi_load32':
    bootinfo32.c:236: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
    bootinfo32.c:239: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]

    biospnp.c: In function 'biospnp_call':
    biospnp.c:258: warning: dereferencing pointer 'argp.40' does break strict-aliasing rules [-Wstrict-aliasing]
    biospnp.c:258: note: initialized from here
    biospnp.c:268: warning: dereferencing pointer 'argp.40' does break strict-aliasing rules [-Wstrict-aliasing]
    biospnp.c:268: note: initialized from here
    biospnp.c:282: warning: dereferencing pointer 'argp.40' does break strict-aliasing rules [-Wstrict-aliasing]
    biospnp.c:282: note: initialized from here

Using bcopy to copy the data around.

History

#1

Updated by Electric Monk 5 months ago

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

git commit 57aea9348dbfeb813b16956eec292357525e2f66

commit  57aea9348dbfeb813b16956eec292357525e2f66
Author: Toomas Soome <tsoome@me.com>
Date:   2019-02-22T17:44:30.000Z

    10429 loader: dereferencing type-punned pointer will break strict-aliasing rules
    Reviewed by: Andy Fiddaman <andy@omniosce.org>
    Approved by: Robert Mustacchi <rm@joyent.com>

Also available in: Atom PDF