xkaraman left a comment (kamailio/kamailio#4484)

Hey @sergey-safarov,

What are you compiler options that resulted in this warning?

I tried to replicated this on `Alpine Linux v3.22` with gcc `gcc version 
14.2.0` but i could not replicate this warning.

Steps i used was:
1. Provide addiotional compile flags to compiler to be more verbose on config 
step:

`CFLAGS='-Wall -Wmaybe-uninitialized' cmake -S . -B build-alpine-redis 
-DINCLUDE_MODULES="ims_qos_npn" -DCMAKE_INSTALL_PREFIX=install/alpine-redis 
--fresh`

2. Try to build with verbose mode to see the flags:

`cmake --build build-alpine-redis/ -j8 -t ims_qos_npn -v`

result in:

 ``` c
cd /code/build-alpine-redis/src/modules/ims_qos_npn && /usr/bin/cc 
-DADAPTIVE_WAIT -DADAPTIVE_WAIT_LOOPS=1024 - \DARCH=\"x86_64\" 
-DCC_GCC_LIKE_ASM -DCFG_DIR=\"/code/install/alpine-redis/etc/kamailio/\" 
-DCOMPILER="\"gcc 14.2.0\"" -DDBG_SR_MEMORY -DDISABLE_NAGLE -DDNS_IP_HACK 
-DFAST_LOCK -DF_MALLOC -DHAVE_ALLOCA_H -DHAVE_EPOLL -DHAVE_GETHOSTBYNAME2 
-DHAVE_IP_MREQN -DHAVE_MSGHDR_MSG_CONTROL -DHAVE_MSG_NOSIGNAL -DHAVE_RESOLV_RES 
-DHAVE_SCHED_SETSCHEDULER -DHAVE_SCHED_YIELD -DHAVE_SELECT -DHAVE_SIGIO_RT 
-DHAVE_TIMEGM -DHAVE_UNION_SEMUN -DKSR_PTHREAD_MUTEX_SHARED -DMALLOC_STATS 
-DMEM_JOIN_FREE -DMOD_NAME=\"ims_qos_npn\" -DMOD_NAMEID=ims_qos_npn 
-DNAME=\"kamailio\" -DOS=Linux -DOS_QUOTED=\"Linux\" -DPKG_MALLOC -DQ_MALLOC 
-DRUN_DIR=\"/run/kamailio\" 
-DSHARE_DIR=\"/code/install/alpine-redis/share/kamailio/\" -DSHM_MMAP 
-DSIGINFO64_WORKAROUND -DSTATISTICS -DTLSF_MALLOC -DTLS_HOOKS -DUSE_CORE_STATS 
-DUSE_DNS_CACHE -DUSE_DNS_FAILOVER -DUSE_DST_BLOCKLIST -DUSE_FUTEX -DUSE_MCAST 
-DUSE_NAPTR -DUSE_RAW_SOCKS -DUSE_SCTP -DUSE_TCP -DUSE_TLS 
-DVERSION=\"6.1.0-dev1\" -DVERSIONVAL=6001000 -D__CPU_x86_64 -D__OS_linux \ 
-Dims_qos_npn_EXPORTS \  **-Wall -Wmaybe-uninitialized** -g -std=gnu11 -fPIC 
-ffile-prefix-map=/code/src/modules/ims_qos_npn/= -fPIC -funroll-loops 
-Wcast-align -m64 -minline-all-stringops -falign-loops -ftree-vectorize 
-fno-strict-overflow -mtune=generic -MD -MT 
src/modules/ims_qos_npn/CMakeFiles/ims_qos_npn.dir/rx_aar.c.o -MF 
CMakeFiles/ims_qos_npn.dir/rx_aar.c.o.d -o 
CMakeFiles/ims_qos_npn.dir/rx_aar.c.o -c /code/src/modules/ims_qos_npn/rx_aar.c
```

`-Wall` and `-Wmaybe-uninitialized` are present.

But there is no warning about uninitialized variables on my side.

I also tried this on Ubuntu with `gcc version 10.5.0 (Ubuntu 
10.5.0-1ubuntu1~20.04)`, with the same results

-- 
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4484#issuecomment-3596895624
You are receiving this because you are subscribed to this thread.

Message ID: <kamailio/kamailio/issues/4484/[email protected]>
_______________________________________________
Kamailio - Development Mailing List -- [email protected]
To unsubscribe send an email to [email protected]
Important: keep the mailing list in the recipients, do not reply only to the 
sender!

Reply via email to