mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
r22833: use EVENT_FD_AUTOCLOSE in our event test suite
(This used to be commit 9109d43595
)
This commit is contained in:
parent
a2b2502585
commit
bb2571cb90
@ -82,7 +82,7 @@ static bool test_event_context(struct torture_context *test,
|
|||||||
/* create a pipe */
|
/* create a pipe */
|
||||||
pipe(fd);
|
pipe(fd);
|
||||||
|
|
||||||
fde = event_add_fd(ev_ctx, ev_ctx, fd[0], EVENT_FD_READ,
|
fde = event_add_fd(ev_ctx, ev_ctx, fd[0], EVENT_FD_READ|EVENT_FD_AUTOCLOSE,
|
||||||
fde_handler, fd);
|
fde_handler, fd);
|
||||||
|
|
||||||
event_add_timed(ev_ctx, ev_ctx, timeval_current_ofs(2,0),
|
event_add_timed(ev_ctx, ev_ctx, timeval_current_ofs(2,0),
|
||||||
@ -105,7 +105,6 @@ static bool test_event_context(struct torture_context *test,
|
|||||||
}
|
}
|
||||||
|
|
||||||
talloc_free(fde);
|
talloc_free(fde);
|
||||||
close(fd[0]);
|
|
||||||
close(fd[1]);
|
close(fd[1]);
|
||||||
|
|
||||||
while (alarm_count < fde_count+1) {
|
while (alarm_count < fde_count+1) {
|
||||||
|
Loading…
Reference in New Issue
Block a user