Send Linux-ha-cvs mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]
You can reach the person managing the list at
[EMAIL PROTECTED]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Linux-ha-cvs digest..."
Today's Topics:
1. Linux-HA CVS: mgmt by zhenh from
([email protected])
2. Linux-HA CVS: mgmt by zhenh from
([email protected])
3. Linux-HA CVS: lib by andrew from
([email protected])
4. Linux-HA CVS: lib by andrew from
([email protected])
----------------------------------------------------------------------
Message: 1
Date: Mon, 23 Jan 2006 00:29:31 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: mgmt by zhenh from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : zhenh
Host :
Project : linux-ha
Module : mgmt
Dir : linux-ha/mgmt/client
Modified Files:
haclient.py.in
Log Message:
fix the GUI client crash bug: check the ret_str before len(ret_str)
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/mgmt/client/haclient.py.in,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -3 -r1.8 -r1.9
--- haclient.py.in 22 Dec 2005 07:21:18 -0000 1.8
+++ haclient.py.in 23 Jan 2006 07:29:30 -0000 1.9
@@ -147,7 +147,7 @@
widgets.append(None)
continue
table.attach(gtk.Label(fields[row].label+":"), 0, 1, row, row+1)
- if fields[row].options != None:
+ if fields[row].options != None and fields[row].options!=[]:
combo = gtk.combo_box_entry_new_text()
for option in fields[row].options:
combo.append_text(option)
@@ -1377,6 +1377,7 @@
# connect to one of the cluster
ip = socket.gethostbyname(server)
if mgmt_connect(ip, username, password) == -1:
+ mgmt_disconnect()
return False
self.connected = True
self.username = username
@@ -1393,11 +1394,11 @@
def do_cmd(self, command) :
ret_str = mgmt_sendmsg(command)
- while len(ret_str)>=4 and ret_str[:4] == "evt:" :
- ret_str = mgmt_recvmsg()
if ret_str == None :
debug(str(string.split(command, "\n"))+":None")
return None
+ while len(ret_str)>=4 and ret_str[:4] == "evt:" :
+ ret_str = mgmt_recvmsg()
ret_list = string.split(ret_str, "\n")
if ret_list[0] != "ok" :
debug(str(string.split(command, "\n"))+":"+
str(ret_list))
------------------------------
Message: 2
Date: Mon, 23 Jan 2006 00:34:22 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: mgmt by zhenh from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : zhenh
Host :
Project : linux-ha
Module : mgmt
Dir : linux-ha/mgmt/daemon
Modified Files:
mgmt_crm.c
Log Message:
fix the GUI client crash bug: when lost cib connect, mgmtd will exit and wait
heartbeat restart it
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/mgmt/daemon/mgmt_crm.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -3 -r1.8 -r1.9
--- mgmt_crm.c 11 Jan 2006 23:53:35 -0000 1.8
+++ mgmt_crm.c 23 Jan 2006 07:34:22 -0000 1.9
@@ -27,6 +27,8 @@
#include <heartbeat.h>
#include <clplumbing/cl_log.h>
#include <clplumbing/cl_syslog.h>
+#include <clplumbing/lsb_exitcodes.h>
+
#include "mgmt_internal.h"
#include <crm/cib.h>
@@ -87,6 +89,7 @@
static int delete_lrm_rsc(IPC_Channel *crmd_channel, const char *host_uname,
const char *rsc_id);
static pe_working_set_t* get_data_set(void);
static void free_data_set(pe_working_set_t* data_set);
+void on_cib_connection_destroy(gpointer user_data);
#define GET_RESOURCE() if (argc != 2) {
\
return cl_strdup(MSG_FAIL);
\
@@ -198,6 +201,8 @@
ret = cib_conn->cmds->add_notify_callback(cib_conn, T_CIB_DIFF_NOTIFY
, on_cib_diff);
+ ret = cib_conn->cmds->set_connection_dnotify(cib_conn
+ , on_cib_connection_destroy);
reg_msg(MSG_CRM_CONFIG, on_get_crm_config);
reg_msg(MSG_UP_CRM_CONFIG, on_update_crm_config);
@@ -257,6 +262,15 @@
}
fire_event(EVT_CIB_CHANGED);
}
+void
+on_cib_connection_destroy(gpointer user_data)
+{
+ mgmt_log(LOG_ERR,"Connection to the CIB terminated... exiting");
+ fire_event(EVT_DISCONNECTED);
+ cib_conn = NULL;
+ exit(LSB_EXIT_OK);
+ return;
+}
/* cluster functions */
char*
------------------------------
Message: 3
Date: Mon, 23 Jan 2006 07:40:49 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: lib by andrew from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : andrew
Host :
Project : linux-ha
Module : lib
Dir : linux-ha/lib/crm/common
Modified Files:
xml.c
Log Message:
Fix memory leak in verification of diff applications
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/lib/crm/common/xml.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -3 -r1.50 -r1.51
--- xml.c 11 Jan 2006 13:10:21 -0000 1.50
+++ xml.c 23 Jan 2006 14:40:48 -0000 1.51
@@ -1,4 +1,4 @@
-/* $Id: xml.c,v 1.50 2006/01/11 13:10:21 andrew Exp $ */
+/* $Id: xml.c,v 1.51 2006/01/23 14:40:48 andrew Exp $ */
/*
* Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]>
*
@@ -1533,9 +1533,6 @@
crm_data_t *added = find_xml_node(diff, "diff-added", FALSE);
crm_data_t *removed = find_xml_node(diff, "diff-removed", FALSE);
- crm_data_t *intermediate = NULL;
- crm_data_t *diff_of_diff = NULL;
-
int root_nodes_seen = 0;
CRM_DEV_ASSERT(new != NULL);
@@ -1569,12 +1566,16 @@
root_nodes_seen++;
);
}
+
if(root_nodes_seen > 1) {
crm_err("(+) Diffs cannot contain more than one change set..."
" saw %d", root_nodes_seen);
result = FALSE;
} else if(result) {
+ crm_data_t *intermediate = NULL;
+ crm_data_t *diff_of_diff = NULL;
+
crm_debug_2("Verification Phase");
intermediate = diff_xml_object(old, *new, FALSE);
diff_of_diff = diff_xml_object(intermediate, diff, TRUE);
@@ -1584,12 +1585,12 @@
log_xml_diff(LOG_INFO, intermediate,
"diff:actual_diff");
result = FALSE;
}
- crm_free(diff_of_diff);
- crm_free(intermediate);
+ free_xml(diff_of_diff);
+ free_xml(intermediate);
diff_of_diff = NULL;
intermediate = NULL;
}
-
+
if(result == FALSE) {
log_xml_diff(LOG_INFO, diff, "diff:input_diff");
------------------------------
Message: 4
Date: Mon, 23 Jan 2006 07:43:08 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: lib by andrew from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : andrew
Host :
Project : linux-ha
Module : lib
Dir : linux-ha/lib/crm/common
Modified Files:
xml.c
Log Message:
Only turn on verification for development builds
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/lib/crm/common/xml.c,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -3 -r1.51 -r1.52
--- xml.c 23 Jan 2006 14:40:48 -0000 1.51
+++ xml.c 23 Jan 2006 14:43:07 -0000 1.52
@@ -1,4 +1,4 @@
-/* $Id: xml.c,v 1.51 2006/01/23 14:40:48 andrew Exp $ */
+/* $Id: xml.c,v 1.52 2006/01/23 14:43:07 andrew Exp $ */
/*
* Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]>
*
@@ -1572,6 +1572,7 @@
" saw %d", root_nodes_seen);
result = FALSE;
+#if CRM_DEV_BUILD
} else if(result) {
crm_data_t *intermediate = NULL;
crm_data_t *diff_of_diff = NULL;
@@ -1589,6 +1590,7 @@
free_xml(intermediate);
diff_of_diff = NULL;
intermediate = NULL;
+#endif
}
if(result == FALSE) {
------------------------------
_______________________________________________
Linux-ha-cvs mailing list
[email protected]
http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs
End of Linux-ha-cvs Digest, Vol 26, Issue 50
********************************************