Skip to content
Snippets Groups Projects
Commit 1ba91ba2 authored by Joakim Tjernlund's avatar Joakim Tjernlund Committed by Wolfgang Denk
Browse files

dlmalloc.c: Fix gcc alias warning

Fix these warnings:
dlmalloc.c: In function 'free':
dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break strict-aliasing rules
dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break strict-aliasing rules
dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break strict-aliasing rules

Some page(http://blog.worldofcoding.com/2010/02/solving-gcc-44-strict-aliasing-problems.html

)
suggests adding __attribute__((__may_alias__)). Doing so makes the warnings go away.

Signed-off-by: default avatarJoakim Tjernlund <Joakim.Tjernlund@transmode.se>
Acked-by: default avatarMike Frysinger <vapier@gentoo.org>
parent d1e0b10a
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment