[Openais] [PATCH] trunk/corosync: fix logsys single id in logsys_config_priority_set
Fabio M. Di Nitto
fabbione at fabbione.net
Mon Aug 4 22:44:53 PDT 2008
Hi Steven,
this hunk was missing from original David patch. Please apply.
Without this fix, it is possible to crach by:
logsys_init(...
and calling logsys_config_priority_set right after because
logsys_subsys_id is not set.
Please apply
Fabio
--
I'm going to make him an offer he can't refuse.
-------------- next part --------------
Index: corosync/exec/logsys.h
===================================================================
--- corosync/exec/logsys.h (revision 1620)
+++ corosync/exec/logsys.h (working copy)
@@ -351,6 +351,9 @@
extern void _logsys_config_priority_set (unsigned int id, unsigned int priority);
#define logsys_config_priority_set(priority) do { \
+ if (logsys_single_id) \
+ logsys_subsys_id = 0; \
+ assert (logsys_subsys_id != -1); \
_logsys_config_priority_set (logsys_subsys_id, priority); \
} while(0)
More information about the Openais
mailing list