[mcedaemon] r82 committed - Add a compile option to disable the check for non-poll() kernels.

1 view
Skip to first unread message

mced...@googlecode.com

unread,
Oct 15, 2011, 1:21:18 AM10/15/11
to mced-...@googlegroups.com
Revision: 82
Author: thockin
Date: Fri Oct 14 22:20:32 2011
Log: Add a compile option to disable the check for non-poll() kernels.


http://code.google.com/p/mcedaemon/source/detail?r=82

Modified:
/trunk/Changelog
/trunk/Makefile
/trunk/mced.c

=======================================
--- /trunk/Changelog Fri Oct 14 21:36:24 2011
+++ /trunk/Changelog Fri Oct 14 22:20:32 2011
@@ -1,6 +1,7 @@
%changelog
* Fri Oct 14 2011 Tim Hockin <tho...@hockin.org>
- Fix innocuous buffer overflow (uds_addr.sun_path). [ud_socket.c]
+ - Add a compile option to disable the check for poll() support.

* Sun Jun 13 2010 Tim Hockin <tho...@hockin.org>
- Bump to 2.0.4 for release.
=======================================
--- /trunk/Makefile Fri Oct 14 21:36:24 2011
+++ /trunk/Makefile Fri Oct 14 22:20:32 2011
@@ -16,6 +16,7 @@
ENABLE_MCEDB ?= 0 # boolean (currently not checked in)
ENABLE_DBUS ?= 0 # boolean
ENABLE_FAKE_DEV_MCELOG ?= 0 # boolean
+CHECK_FOR_NON_POLL_KERNELS ?= 0 # boolean

# include the generic rules
include $(TOPDIR)/Makerules.mk
@@ -28,6 +29,7 @@
CPPFLAGS += -DENABLE_MCEDB=$(ENABLE_MCEDB)
CPPFLAGS += -DENABLE_DBUS=$(ENABLE_DBUS)
CPPFLAGS += -DENABLE_FAKE_DEV_MCELOG=$(ENABLE_FAKE_DEV_MCELOG)
+CPPFLAGS += -DCHECK_FOR_NON_POLL_KERNELS=$(CHECK_FOR_NON_POLL_KERNELS)
ifneq "$(strip $(ENABLE_MCEDB))" "0"
LIBS += -ldb
endif
=======================================
--- /trunk/mced.c Tue Apr 20 10:28:30 2010
+++ /trunk/mced.c Fri Oct 14 22:20:32 2011
@@ -860,7 +860,11 @@
static int
check_mcelog_poll(int mce_fd)
{
- //FIXME: on a machine with a lot of errors, this loops forever!
+ if (!CHECK_FOR_NON_POLL_KERNELS) {
+ return 1;
+ }
+
+ // On a machine with a lot of errors, this loops forever!
while (1) {
int r;
struct pollfd ar[1];

Reply all
Reply to author
Forward
0 new messages