``` CC (clang38) [M ims_dialog.so] dlg_hash.o dlg_hash.c:674:37: warning: equality comparison with extraneous parentheses [-Wparentheses-equality] if ((d_entry_out->first == d_entry_out->last)) { ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~ dlg_hash.c:674:37: note: remove extraneous parentheses around the comparison to silence this warning if ((d_entry_out->first == d_entry_out->last)) { ~ ^ ~ dlg_hash.c:674:37: note: use '=' to turn this equality comparison into an assignment if ((d_entry_out->first == d_entry_out->last)) { ^~ =
CC (clang38) [M ims_qos.so] rx_avp.o rx_avp.c:492:16: warning: comparison of unsigned expression >= 0 is always true [-Wtautological-compare] if (bandwidth >= 0) { ~~~~~~~~~ ^ ~ rx_avp.c:504:16: warning: comparison of unsigned expression >= 0 is always true [-Wtautological-compare] if (bandwidth >= 0) { ~~~~~~~~~ ^ ~
CC (clang38) [M ims_registrar_scscf.so] save.o save.c:114:21: warning: comparison of unsigned expression >= 0 is always true [-Wtautological-compare] if (expires_hdr >= 0) ~~~~~~~~~~~ ^ ~ ``` You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/637
-- Commit Summary --
* modules/ims_auth lib/ims: use header type instead of header flag * modules/ims_qos modules/ims_registrar_scscf: fix comparison of unsigned expression * modules/ims_dialog: fix clang warning -Wparentheses-equality
-- File Changes --
M lib/ims/ims_getters.c (6) M modules/ims_auth/utils.c (4) M modules/ims_dialog/dlg_hash.c (2) M modules/ims_qos/rx_avp.c (4) M modules/ims_registrar_scscf/save.c (2)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/637.patch https://github.com/kamailio/kamailio/pull/637.diff
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637
For the commit 94b4c25, is it handling properly the value 0?
Not dug much into the code, so this is more like a safety check to see that the return code or the parameter was not supposed to be negative in case of error or missing expires header.
Given those patches are related to ims modules, maybe @jaybeepee, @richardgood or @ngvoice may want to take a look.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-221683275
Uh, thanks. I should not have stared those warnings with too narrow view.
Maybe more proper Wtautological-compare fix is then to declare bandwidth and expires_hdr as 'int'. Type is now 'unsigned int'.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-221816620
Yes, using signed int might be a solution. Maybe you can discard/revert the patch 94b4c25, so the others can be merged.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-222936556
Sure, reverted. Travis CI check passed, but it looks like it does not try to build any ims modules.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-223328318
Yes, on travis We build only the modules included in the group standard
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-223508606
@linuxmaniac can we enable some more groups? I would be interested in the one very important such as tls, websocket, presence ...
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-223508946
I'm on it. I'm going to build all modules provided by debian packages.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-223509327
Great, thanks! I will merge this pull request.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#issuecomment-223509651
Merged #637.
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/pull/637#event-680792334