-
Type:
Incident report
-
Resolution: Unresolved
-
Priority:
Trivial
-
None
-
Affects Version/s: None
-
Component/s: Proxy (P), Server (S)
-
None
-
Environment:Alpine 3.23
Would be great to avoid the following format warnings:
#14 67.16 ../../../include/common/zbxtypes.h:123:53: note: format string is defined here #14 67.16 123 | # define ZBX_FS_I64 "%lld" #14 67.16 | ~~~^ #14 67.16 | | #14 67.16 | long long int #14 67.16 | %ld #14 67.16 taskmanager_proxy.c:647:34: warning: format '%lld' expects argument of type 'long long int', but argument 5 has type 'long int' [-Wformat=] #14 67.16 647 | zbx_setproctitle("%s [processed %d task(s) in " ZBX_FS_DBL " sec, idle " ZBX_FS_TIME_T " sec]", #14 67.16 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #14 67.16 648 | get_process_type_string(process_type), tasks_num, sec2 - sec1, #14 67.16 649 | (zbx_fs_time_t)sleeptime); #14 67.16 | ~~~~~~~~~~~~~~~~~~~~~~~~ #14 67.16 | | #14 67.16 | long int #14 67.16 ../../../include/common/zbxtypes.h:123:53: note: format string is defined here #14 67.16 123 | # define ZBX_FS_I64 "%lld" #14 67.16 | ~~~^ #14 67.16 | | #14 67.16 | long long int #14 67.16 | %ld #14 67.24 Making all in trapper #14 67.36 Making all in proxyconfigwrite #14 67.43 proxyconfigwrite.c: In function 'proxyconfig_update_rows': #14 67.43 proxyconfigwrite.c:1034:75: warning: format '%llu' expects argument of type 'long long unsigned int', but argument 6 has type 'uint64_t' {aka 'long unsigned int'} [-Wformat=] #14 67.43 1034 | zbx_snprintf_alloc(&sql, &sql_alloc, &sql_offset, " where %s=" ZBX_FS_UI64 ";\n", #14 67.43 | ^~~~~~~~~~~~ #14 67.43 1035 | td->table->recid, row->recid); #14 67.43 | ~~~~~~~~~~ #14 67.43 | | #14 67.43 | uint64_t {aka long unsigned int} #14 67.43 In file included from ../../../include/module.h:18, #14 67.43 from ../../../include/zbxcommon.h:19, #14 67.43 from ../../../include/zbxnum.h:18, #14 67.43 from ../../../include/zbxalgo.h:18, #14 67.43 from ../../../include/zbxcomms.h:18, #14 67.43 from proxyconfigwrite.h:18, #14 67.43 from proxyconfigwrite.c:15: #14 67.43 ../../../include/common/zbxtypes.h:100:53: note: format string is defined here #14 67.43 100 | # define ZBX_FS_UI64 "%llu" #14 67.43 | ~~~^ #14 67.43 | | #14 67.43 | long long unsigned int #14 67.43 | %lu #14 67.43 proxyconfigwrite.c: In function 'zbx_proxyconfig_process': #14 67.43 proxyconfigwrite.c:2339:30: warning: format '%lld' expects argument of type 'long long int', but argument 4 has type 'long int' [-Wformat=] #14 67.43 2339 | zabbix_log(loglevel, "received configuration data from server at \"%s\", datalen " ZBX_FS_SSIZE_T, #14 67.43 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #14 67.43 2340 | addr, (zbx_fs_ssize_t)(jp->end - jp->start + 1)); #14 67.43 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #14 67.43 | | #14 67.43 | long int #14 67.43 ../../../include/zbxcommon.h:789:47: note: in definition of macro 'zabbix_log' #14 67.43 789 | zbx_log_handle(level, __VA_ARGS__); \ #14 67.43 | ^~~~~~~~~~~
and
#14 32.57 In file included from ../../../include/zbxdbhigh.h:18, #14 32.57 from template_item.c:15: #14 32.57 In function 'zbx_vector_template_item_ptr_append_array', #14 32.57 inlined from 'zbx_vector_template_item_ptr_append_array' at template_item.c:126:1, #14 32.57 inlined from 'link_template_dependent_items' at template_item.c:2647:2, #14 32.57 inlined from 'DBcopy_template_items' at template_item.c:3335:2: #14 32.57 ../../../include/zbxalgo.h:469:9: warning: 'memcpy' specified bound between 18446744056529682440 and 18446744073709551608 exceeds maximum object size 9223372036854775807 [-Wstringop-overflow=] #14 32.57 469 | memcpy(vector->values + vector->values_num, values, (size_t)values_num * sizeof(__type)); \ #14 32.57 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #14 32.57 ../../../include/zbxalgo.h:651:1: note: in expansion of macro 'ZBX_VECTOR_FUNC_IMPL' #14 32.57 651 | ZBX_VECTOR_FUNC_IMPL(__id, __type, const) \ #14 32.57 | ^~~~~~~~~~~~~~~~~~~~ #14 32.57 template_item.c:126:1: note: in expansion of macro 'ZBX_PTR_VECTOR_IMPL' #14 32.57 126 | ZBX_PTR_VECTOR_IMPL(template_item_ptr, zbx_template_item_t*) #14 32.57 | ^~~~~~~~~~~~~~~~~~~