summaryrefslogtreecommitdiff
path: root/source4/lib/events/events_select.c
diff options
context:
space:
mode:
authorSimo Sorce <idra@samba.org>2008-06-14 11:23:31 -0400
committerSimo Sorce <idra@samba.org>2008-06-14 11:59:19 -0400
commit2aba4107915611b223daa8c27c52352f57b25bbc (patch)
treeb97a1f2408c3101ca8e66faa6851848d829e4f5f /source4/lib/events/events_select.c
parent3443954c2bf971c3506aa40667989a10d5769706 (diff)
downloadsamba-2aba4107915611b223daa8c27c52352f57b25bbc.tar.gz
samba-2aba4107915611b223daa8c27c52352f57b25bbc.tar.bz2
samba-2aba4107915611b223daa8c27c52352f57b25bbc.zip
This patch make it possible to build the events library completely
standalone with no ties to internal samba4 functions Samba4 itself just uses the plain library, compatibility glue is in events_s4.c only (This used to be commit 7109b6a5a19eb2dbef4259104858b171298bad6e)
Diffstat (limited to 'source4/lib/events/events_select.c')
-rw-r--r--source4/lib/events/events_select.c22
1 files changed, 3 insertions, 19 deletions
diff --git a/source4/lib/events/events_select.c b/source4/lib/events/events_select.c
index 16fff71e4a..9e97d2b39f 100644
--- a/source4/lib/events/events_select.c
+++ b/source4/lib/events/events_select.c
@@ -23,13 +23,7 @@
*/
-#if _SAMBA_BUILD_
-#include "includes.h"
-#include "lib/util/dlinklist.h"
-#else
#include "replace.h"
-#include "events_util.h"
-#endif
#include "system/filesys.h"
#include "system/select.h"
#include "events.h"
@@ -221,9 +215,8 @@ static int select_event_loop_select(struct select_event_context *select_ev, stru
made readable and that should have removed
the event, so this must be a bug. This is a
fatal error. */
-#if _SAMBA_BUILD_
- DEBUG(0,("ERROR: EBADF on select_event_loop_once\n"));
-#endif
+ ev_debug(select_ev->ev, EV_DEBUG_FATAL,
+ "ERROR: EBADF on select_event_loop_once\n");
select_ev->exit_code = EBADF;
return -1;
}
@@ -265,7 +258,7 @@ static int select_event_loop_once(struct event_context *ev)
struct timeval tval;
tval = common_event_loop_timer_delay(ev);
- if (timeval_is_zero(&tval)) {
+ if (ev_timeval_is_zero(&tval)) {
return 0;
}
@@ -306,12 +299,3 @@ bool events_select_init(void)
return event_register_backend("select", &select_event_ops);
}
-#if _SAMBA_BUILD_
-_PUBLIC_ NTSTATUS s4_events_select_init(void)
-{
- if (!events_select_init()) {
- return NT_STATUS_INTERNAL_ERROR;
- }
- return NT_STATUS_OK;
-}
-#endif