[ZBX-12493] Move depends on uninitialised value when using IPMI Created: 2017 Aug 09 Updated: 2017 Sep 07 Resolved: 2017 Sep 07 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Proxy (P), Server (S) |
Affects Version/s: | 2.2.20rc1, 3.0.11rc1, 3.2.8rc1, 3.4.0rc1 |
Fix Version/s: | 2.2.20rc1, 3.0.11rc1, 3.2.8rc1, 3.4.2rc1, 4.0.0alpha1 |
Type: | Problem report | Priority: | Trivial |
Reporter: | Vladislavs Sokurenko | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | ipmi | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Attachments: | ZBX-12483.diff |
Team: | Team A |
Sprint: | Sprint 16 |
Story Points: | 1.5 |
Description |
Valgrind produces following error: ==10886== Conditional jump or move depends on uninitialised value(s) ==10886== at 0x5481205: ipmi_lanp_setup_con (in /usr/lib64/libOpenIPMI.so.0.0.5) ==10886== by 0x54820C6: ipmi_ip_setup_con (in /usr/lib64/libOpenIPMI.so.0.0.5) ==10886== by 0x42B4BB: zbx_init_ipmi_host (checks_ipmi.c:1236) ==10886== by 0x42CD22: get_value_ipmi (checks_ipmi.c:1420) ==10886== by 0x42945B: ipmi_poller_process_value_request (ipmi_poller.c:111) ==10886== by 0x42945B: ipmi_poller_thread (ipmi_poller.c:242) ==10886== by 0x474459: zbx_thread_start (threads.c:128) ==10886== by 0x418DE9: MAIN_ZABBIX_ENTRY (proxy.c:1097) ==10886== by 0x469352: daemon_start (daemon.c:392) ==10886== by 0x417A56: main (proxy.c:847) ==10886== Uninitialised value was created by a stack allocation ==10886== at 0x42B260: zbx_init_ipmi_host (checks_ipmi.c:1211 It appears that OpenIPMI sets port without respect of port count variable, it only checks that port is not NULL: 5583 for (i=0; i<MAX_IP_ADDR; i++) { 5584 if (!ports[i]) 5585 ports[i] = IPMI_LAN_STD_PORT_STR; 5586 } Please also see patch attached, though OpenIPMI code must be carefully analyzed before changes are made. |
Comments |
Comment by Andris Mednis [ 2017 Sep 04 ] |
Confirmed with OpenIPMI-2.0.22. |
Comment by Andris Mednis [ 2017 Sep 05 ] |
Fixed in development branches:
|
Comment by Vladislavs Sokurenko [ 2017 Sep 07 ] |
Successfully tested |
Comment by Andris Mednis [ 2017 Sep 07 ] |
Thanks! See improved comment in svn://svn.zabbix.com/branches/dev/ZBX-12493-22, r72320. vso looks good. |
Comment by Andris Mednis [ 2017 Sep 07 ] |
Available in versions:
|
Comment by Andris Mednis [ 2017 Sep 07 ] |
No documentation changes required. |