
# HG changeset patch # User Dan Smith <danms@us.ibm.com> # Date 1214857687 25200 # Node ID 02aaaea433146ad4f6dc5c63b34701bc46567fb4 # Parent f72441bf10fdd467d3f47d33e4bfb29537cc53e1 Fix CSI failure path Since connect_by_classname() can return NULL without it being an error condition, printing the status message is not valid unless you check the s.rc field. I don't think the message adds much here, since there is only one place that the message is filled out, and it's a static string. Instead, change the debug message to something useful to avoid the SEGV. Signed-off-by: Dan Smith <danms@us.ibm.com> diff -r f72441bf10fd -r 02aaaea43314 src/Virt_ComputerSystemIndication.c --- a/src/Virt_ComputerSystemIndication.c Mon Jun 30 13:12:21 2008 -0700 +++ b/src/Virt_ComputerSystemIndication.c Mon Jun 30 13:28:07 2008 -0700 @@ -339,7 +339,8 @@ conn = connect_by_classname(_BROKER, args->classname, &s); if (conn == NULL) { - CU_DEBUG("Failed to connect: %s", CMGetCharPtr(s.msg)); + CU_DEBUG("Unable to start lifecycle thread: " + "Failed to connect (cn: %s)", args->classname); goto out; }