This patch fixes an infinite loop that was observed with a buggy BMC that has 
an empty SDR.
The loop occured inside ipmi_sdr_find_sdr_bynumtype().

diff --git a/lib/ipmi_sdr.c b/lib/ipmi_sdr.c
index 950c5c9..dd28fe9 100644
--- a/lib/ipmi_sdr.c
+++ b/lib/ipmi_sdr.c
@@ -664,6 +664,9 @@ ipmi_sdr_get_header(struct ipmi_intf *intf, struct 
ipmi_sdr_iterator *itr)
                }
        }
 
+       if (try == 5)
+               return NULL;
+
        if (!rsp)
                return NULL;
 


-- 
Dan Aloni
XIV LTD, http://www.xivstorage.com
da-x (at) monatomic.org, dan (at) xiv.co.il

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Ipmitool-devel mailing list
Ipmitool-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ipmitool-devel

Reply via email to