diff options
author | bubulle <bubulle@alioth.debian.org> | 2011-03-07 19:04:15 +0000 |
---|---|---|
committer | bubulle <bubulle@alioth.debian.org> | 2011-03-07 19:04:15 +0000 |
commit | 4d16e8d5702fb98dda73c5c0f3404d662ae62df6 (patch) | |
tree | fc3a71a0b741cbcc6a5a892f91cc0f2218dfe656 /source3/smbd/conn.c | |
parent | 9fbd7973837d958b90261b85fafff36ac194ba58 (diff) | |
download | samba-4d16e8d5702fb98dda73c5c0f3404d662ae62df6.tar.gz |
Load samba-3.5.8 into branches/samba/upstream.upstream/3.5.8_dfsg
git-svn-id: svn://svn.debian.org/svn/pkg-samba/branches/samba/upstream@3691 fc4039ab-9d04-0410-8cac-899223bdd6b0
Diffstat (limited to 'source3/smbd/conn.c')
-rw-r--r-- | source3/smbd/conn.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/source3/smbd/conn.c b/source3/smbd/conn.c index 959fcd7754..37c2311be8 100644 --- a/source3/smbd/conn.c +++ b/source3/smbd/conn.c @@ -197,6 +197,7 @@ bool conn_idle_all(struct smbd_server_connection *sconn,time_t t) int deadtime = lp_deadtime()*60; pipes_struct *plist = NULL; connection_struct *conn; + bool ret = true; if (deadtime <= 0) deadtime = DEFAULT_SMBD_TIMEOUT; @@ -209,6 +210,7 @@ bool conn_idle_all(struct smbd_server_connection *sconn,time_t t) if (conn->lastused != conn->lastused_count) { conn->lastused = t; conn->lastused_count = t; + age = 0; } /* close dirptrs on connections that are idle */ @@ -217,7 +219,7 @@ bool conn_idle_all(struct smbd_server_connection *sconn,time_t t) } if (conn->num_files_open > 0 || age < deadtime) { - return False; + ret = false; } } @@ -229,11 +231,12 @@ bool conn_idle_all(struct smbd_server_connection *sconn,time_t t) for (plist = get_first_internal_pipe(); plist; plist = get_next_internal_pipe(plist)) { if (num_pipe_handles(plist->pipe_handles) != 0) { - return False; + ret = false; + break; } } - return True; + return ret; } /**************************************************************************** |