Skip to content

Commit

Permalink
RPC: stops the release_pipe() funtion from being called twice
Browse files Browse the repository at this point in the history
 This patch stops the release_pipe() funtion from being called
 twice by invalidating the ops pointer in the rpc_inode
 when rpc_pipe_release() is called.

 Signed-off-by: Steve Dickson <[email protected]>
 Signed-off-by: Trond Myklebust <[email protected]>
  • Loading branch information
stevedd authored and Trond Myklebust committed Oct 19, 2005
1 parent 7f709a4 commit 747c553
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions net/sunrpc/rpc_pipe.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ rpc_pipe_release(struct inode *inode, struct file *filp)
__rpc_purge_upcall(inode, -EPIPE);
if (rpci->ops->release_pipe)
rpci->ops->release_pipe(inode);
if (!rpci->nreaders && !rpci->nwriters)
rpci->ops = NULL;
out:
up(&inode->i_sem);
return 0;
Expand Down

0 comments on commit 747c553

Please sign in to comment.