workaround for bug in OpenBSD headers

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@17226 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-09-17 12:24:33 +00:00
parent d55a4efc0f
commit f0e2ef329d
2 changed files with 38 additions and 10 deletions

View File

@@ -44,13 +44,27 @@
#endif
#include <unistd.h>
// TODO: use configure test to detect which of select()/poll() is available!
#if defined(__DARWIN__)
# warning "FIXME: select must be used instead of poll (GD)"
#warning "FIXME: select must be used instead of poll (GD)"
#elif defined(__VMS)
# include <poll.h>
#include <poll.h>
#else
# include <sys/poll.h>
#endif
// bug in the OpenBSD headers: at least in 3.1 there is no extern "C" in
// neither poll.h nor sys/poll.h which results in link errors later
#ifdef __OPENBSD__
extern "C"
{
#endif
#include <sys/poll.h>
#ifdef __OPENBSD__
};
#endif
#endif // platform
#include "wx/gtk/win_gtk.h"
#include <gtk/gtk.h>
@@ -545,7 +559,7 @@ bool wxApp::SendIdleEvents( wxWindow* win )
event.SetEventObject(win);
win->GetEventHandler()->ProcessEvent(event);
if (event.MoreRequested())
needMore = TRUE;

View File

@@ -44,13 +44,27 @@
#endif
#include <unistd.h>
// TODO: use configure test to detect which of select()/poll() is available!
#if defined(__DARWIN__)
# warning "FIXME: select must be used instead of poll (GD)"
#warning "FIXME: select must be used instead of poll (GD)"
#elif defined(__VMS)
# include <poll.h>
#include <poll.h>
#else
# include <sys/poll.h>
#endif
// bug in the OpenBSD headers: at least in 3.1 there is no extern "C" in
// neither poll.h nor sys/poll.h which results in link errors later
#ifdef __OPENBSD__
extern "C"
{
#endif
#include <sys/poll.h>
#ifdef __OPENBSD__
};
#endif
#endif // platform
#include "wx/gtk/win_gtk.h"
#include <gtk/gtk.h>
@@ -545,7 +559,7 @@ bool wxApp::SendIdleEvents( wxWindow* win )
event.SetEventObject(win);
win->GetEventHandler()->ProcessEvent(event);
if (event.MoreRequested())
needMore = TRUE;