-
Incident report
-
Resolution: Fixed
-
Major
-
3.0.1, 3.0.2
-
Solaris 10 SPARC
Compilation of Zabbix server/proxy on Solaris SPARC fails with error:
snmptrapper.c: In function `read_traps': snmptrapper.c:416: error: `INT_MAX' undeclared (first use in this function) snmptrapper.c:416: error: (Each undeclared identifier is reported only once snmptrapper.c:416: error: for each function it appears in.) snmptrapper.c: In function `open_trap_file': snmptrapper.c:475: error: `INT_MAX' undeclared (first use in this function) snmptrapper.c: In function `get_latest_data': snmptrapper.c:541: error: `INT_MAX' undeclared (first use in this function)
I solved it by replacing INT_MAX with ZBX_MAX_UINT64 in file src/zabbix_server/snmptrapper/snmptrapper.c:
416c416 < if (INT_MAX < (zbx_uint64_t)trap_lastsize + nbytes) --- > if (ZBX_MAX_UINT64 < (zbx_uint64_t)trap_lastsize + nbytes) 475c475 < if (INT_MAX < file_buf.st_size) --- > if (ZBX_MAX_UINT64 < file_buf.st_size) 541c541 < else if (INT_MAX < file_buf.st_size) --- > else if (ZBX_MAX_UINT64 < file_buf.st_size)
There were the issues like this before: ZBX-5782 and ZBX-4555.