Description of problem: When compiled with -Wall the example in dlopen.3 there are warnings: [dumas@localhost examples]$ gcc -Wall -g -O2 dlsym.c -o dlsym -ldl dlsym.c: In function 'main': dlsym.c:12: warning: implicit declaration of function 'exit' dlsym.c:12: warning: incompatible implicit declaration of built-in function 'exit' dlsym.c:16: warning: dereferencing type-punned pointer will break strict-aliasing rules dlsym.c:19: warning: incompatible implicit declaration of built-in function 'exit' dlsym.c:24: warning: control reaches end of non-void function The warning: control reaches end of non-void function is not problematic, the exit error is fixed with #include <stdlib.h> but the dlsym.c:16: warning: dereferencing type-punned pointer will break strict-aliasing rules seems really problematic to me. Version-Release number of selected component (if applicable): man-pages-2.36-2 How reproducible: cut and paste the example in man dlopen compile with gcc -Wall -g -O2 Steps to Reproduce: 1. 2. 3. Actual results: strict-aliasing is broken Expected results: no break of strict-aliasing Additional info:
This update doesn't fix the most annoying warning, namely dlsym.c:16: warning: dereferencing type-punned pointer will break strict-aliasing rules I reopen the bug.