diff options
author | Andreas Schneider <asn@samba.org> | 2011-06-21 14:46:16 +0200 |
---|---|---|
committer | Andreas Schneider <asn@samba.org> | 2011-07-14 16:10:47 +0200 |
commit | 68520ec02cafde1f38e8630b67292d921ce30f34 (patch) | |
tree | 5bbcfc8cfffcd13ec9d0f9357bc8040abe4759c8 /source3 | |
parent | 7da54eab641a0b9fa2aca63cbf3364cb34efb812 (diff) | |
download | samba-68520ec02cafde1f38e8630b67292d921ce30f34.tar.gz samba-68520ec02cafde1f38e8630b67292d921ce30f34.tar.bz2 samba-68520ec02cafde1f38e8630b67292d921ce30f34.zip |
s3-smbd: Pass ev_ctx to remove_child_pid().
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/server.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source3/smbd/server.c b/source3/smbd/server.c index aadac6ad0b..30d4ecf064 100644 --- a/source3/smbd/server.c +++ b/source3/smbd/server.c @@ -237,7 +237,9 @@ static void cleanup_timeout_fn(struct event_context *event_ctx, (*cleanup_te) = NULL; } -static void remove_child_pid(pid_t pid, bool unclean_shutdown) +static void remove_child_pid(struct tevent_context *ev_ctx, + pid_t pid, + bool unclean_shutdown) { struct child_pid *child; static struct timed_event *cleanup_te; @@ -253,7 +255,7 @@ static void remove_child_pid(pid_t pid, bool unclean_shutdown) if (!cleanup_te) { /* call the cleanup timer, but not too often */ int cleanup_time = lp_parm_int(-1, "smbd", "cleanuptime", 20); - cleanup_te = event_add_timed(server_event_context(), NULL, + cleanup_te = event_add_timed(ev_ctx, NULL, timeval_current_ofs(cleanup_time, 0), cleanup_timeout_fn, &cleanup_te); @@ -323,7 +325,7 @@ static void smbd_sig_chld_handler(struct tevent_context *ev, if (WIFSIGNALED(status)) { unclean_shutdown = True; } - remove_child_pid(pid, unclean_shutdown); + remove_child_pid(ev, pid, unclean_shutdown); } } |