summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2009-01-06 11:32:46 +0100
committerVolker Lendecke <vl@samba.org>2009-01-09 22:48:09 +0100
commitc1a8e8adac501cdead692f298f8dea0c20bafc76 (patch)
tree40bb6f4b2f5b1f50bdf68654df83be00cf51eec9 /source3/rpc_server
parent2714ac4d3ab40bcd53acb2b86b9dc774040851c8 (diff)
downloadsamba-c1a8e8adac501cdead692f298f8dea0c20bafc76.tar.gz
samba-c1a8e8adac501cdead692f298f8dea0c20bafc76.tar.bz2
samba-c1a8e8adac501cdead692f298f8dea0c20bafc76.zip
Simplify find_pipe_fns_by_context slightly
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_pipe.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/source3/rpc_server/srv_pipe.c b/source3/rpc_server/srv_pipe.c
index 980630cb94..03d9c5b208 100644
--- a/source3/rpc_server/srv_pipe.c
+++ b/source3/rpc_server/srv_pipe.c
@@ -2201,21 +2201,17 @@ bool api_pipe_schannel_process(pipes_struct *p, prs_struct *rpc_in, uint32 *p_ss
static PIPE_RPC_FNS* find_pipe_fns_by_context( PIPE_RPC_FNS *list, uint32 context_id )
{
PIPE_RPC_FNS *fns = NULL;
- PIPE_RPC_FNS *tmp = NULL;
if ( !list ) {
DEBUG(0,("find_pipe_fns_by_context: ERROR! No context list for pipe!\n"));
return NULL;
}
- for (tmp=list; tmp; tmp=tmp->next ) {
- if ( tmp->context_id == context_id )
- break;
+ for (fns=list; fns; fns=fns->next ) {
+ if ( fns->context_id == context_id )
+ return fns;
}
-
- fns = tmp;
-
- return fns;
+ return NULL;
}
/****************************************************************************