These was a bug introduced in the cleanup patch I posted last
night. The problem is that we should only remove a resource from the
cleanup list for the local node/process.
Here is a patch tha fixes the problem.
Index: test/Makefile.am
===================================================================
--- test/Makefile.am (revision 2034)
+++ test/Makefile.am (working copy)
@@ -22,7 +22,7 @@
AM_CFLAGS = $(coroipcc_CFLAGS) $(corosync_CFLAGS)
coro_LIBS = $(coroipcc_LIBS)
-noinst_PROGRAMS = testckpt testevt testmsg testmsg2 testmsg3
testlck testlck2 testclm testtmr ckptbench
+noinst_PROGRAMS = testckpt testevt testmsg testmsg2 testmsg3
testlck testlck2 testlck3 testclm testtmr ckptbench
noinst_HEADERS = sa_error.h
@@ -54,6 +54,10 @@
testlck2_LDADD = -lSaLck
testlck2_LDFLAGS = -L../lib $(coro_LIBS)
+testlck3_SOURCES = testlck3.c sa_error.c
+testlck3_LDADD = -lSaLck
+testlck3_LDFLAGS = -L../lib $(coro_LIBS)
+
testclm_SOURCES = testclm.c sa_error.c
testclm_LDADD = -lSaClm
testclm_LDFLAGS = -L../lib $(coro_LIBS)
Index: services/lck.c
===================================================================
--- services/lck.c (revision 2034)
+++ services/lck.c (working copy)
@@ -2294,18 +2294,6 @@
free (resource);
}
- /*
- * Remove the cleanup entry for this resource.
- */
- cleanup = lck_resource_cleanup_find (
- req_exec_lck_resourceclose->source.conn,
- &req_exec_lck_resourceclose->resource_name);
-
- assert (cleanup != NULL);
-
- list_del (&cleanup->cleanup_list);
- free (cleanup);
-
error_exit:
if (api->ipc_source_is_local (&req_exec_lck_resourceclose->source))
{
@@ -2323,6 +2311,18 @@
}
if (error == SA_AIS_OK) {
+ /*
+ * Remove the cleanup entry for this resource.
+ */
+ cleanup = lck_resource_cleanup_find (
+ req_exec_lck_resourceclose->source.conn,
+ &req_exec_lck_resourceclose->resource_name);
+
+ if (cleanup != NULL) {
+ list_del (&cleanup->cleanup_list);
+ free (cleanup);
+ }
+
hdb_handle_put (&resource_hdb,
req_exec_lck_resourceclose->resource_id);
hdb_handle_destroy (&resource_hdb,
req_exec_lck_resourceclose->resource_id);
}
_______________________________________________
Openais mailing list
[email protected]
https://lists.linux-foundation.org/mailman/listinfo/openais