sipwise / rtpengine

The Sipwise media proxy for Kamailio
GNU General Public License v3.0
778 stars 368 forks source link

atomic64_get stringop-overflow build warning (Fedora 36) #1478

Open amessina opened 2 years ago

amessina commented 2 years ago

Full build log available: https://download.copr.fedorainfracloud.org/results/amessina/mss/fedora-36-x86_64/04221996-rtpengine/build.log.gz

make[1]: Entering directory '/builddir/build/BUILD/rtpengine-mr10.3.1.9/daemon'
gcc -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -Wl,-dT,/builddir/build/BUILD/rtpengine-mr10.3.1.9/.package_note-rtpengine-10.3.1.9^20220411gf160a303-1.fc36.x86_64.ld -rdynamic -rdynamic -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -pthread -fno-strict-aliasing -std=c99 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -pthread  -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -pthread         -I/usr/include/json-glib-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -I/usr/include/libmount -I/usr/include/blkid -pthread    -DWITH_IPTABLES_OPTION -I. -I../kernel-module/ -I../lib/ -I../include/ -D_GNU_SOURCE -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg   -DWITH_TRANSCODING -I/usr/include/mysql -I/usr/include/mysql/mysql -DHAVE_BCG729  -DHAVE_MQTT  -DRTPENGINE_VERSION="\"10.3.1.9^20220411gf160a303-1.fc36\""  -DHAVE_LIBSYSTEMD -pthread -fno-strict-aliasing -std=c99 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -pthread  -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -pthread         -I/usr/include/json-glib-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -I/usr/include/libmount -I/usr/include/blkid -pthread    -DWITH_IPTABLES_OPTION -I. -I../kernel-module/ -I../lib/ -I../include/ -D_GNU_SOURCE -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg  -I/usr/include/ffmpeg   -DWITH_TRANSCODING -I/usr/include/mysql -I/usr/include/mysql/mysql -DHAVE_BCG729  -DHAVE_MQTT  -DRTPENGINE_VERSION="\"10.3.1.9^20220411gf160a303-1.fc36\""  -DHAVE_LIBSYSTEMD -o rtpengine main.o kernel.o poller.o aux.o control_tcp.o call.o control_udp.o redis.o bencode.o cookie_cache.o udp_listener.o control_ng.strhash.o sdp.strhash.o stun.o rtcp.o crypto.o rtp.o call_interfaces.strhash.o dtls.o log.o cli.o graphite.o ice.o media_socket.o homer.o recording.o statistics.o cdr.o ssrc.o iptables.o tcp_listener.o codec.o load.o dtmf.o timerthread.o media_player.o jitter_buffer.o t38.o websocket.o mqtt.o janus.strhash.o loglib.o auxlib.o rtplib.o str.o socket.o streambuf.o ssllib.o dtmflib.o codeclib.o resample.o -lm -lglib-2.0  -lgthread-2.0 -pthread -lglib-2.0  -lz  -lpcre  -lcrypto  -lssl -lcrypto  -levent_pthreads -levent  -lpcap -lxmlrpc_client  -lxmlrpc  -lxmlrpc_util  -lhiredis -ljson-glib-1.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0  -lwebsockets  -lip4tc -lip6tc  -lavcodec  -lavformat  -lavutil  -lswresample  -lavfilter  -lspandsp  -L/usr/lib64/ -lmariadb -lbcg729  -L/usr/lib -lmosquitto  -lsystemd 
make[1]: Leaving directory '/builddir/build/BUILD/rtpengine-mr10.3.1.9/daemon'
In function 'atomic64_get',
    inlined from 'transcode_rr' at rtcp.c:1328:25:
../include/aux.h:429:27: warning: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Wstringop-overflow=]
  429 |         return (uint64_t) g_atomic_pointer_get(p);
      |                           ^
rfuchs commented 2 years ago

Not sure what to make of this one. Almost certainly a spurious false warning. No idea how to silence it because I'm not seeing it myself.

rfuchs commented 2 years ago

In fact I'm not seeing this warning even on a freshly installed Fedora 36. What's your secret?

amessina commented 2 years ago

I'm building in a Koji/Mock or Copr environment -- no secret that I can find either. Here's the build log and spec file from a Koji/Mock build for F36 (the build machine is still F35).

build.log

rtpengine.spec.txt

amessina commented 2 years ago

Here's the link to Copr builds with various Fedora versions and archs: https://copr.fedorainfracloud.org/coprs/amessina/mss/build/4305626/