diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2006-12-13 03:35:10 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-13 12:05:53 -0500 |
commit | a71113da44063b587b5a4c2fc94c948a14f2bb43 (patch) | |
tree | c2b804232dcda3e403d43977e7329c21e787e242 /fs/smbfs/proc.c | |
parent | 3cec556a84be02bcd8755422eec61f1b9bee4e2f (diff) |
[PATCH] smbfs: Make conn_pid a struct pid
smbfs keeps track of the user space server process in conn_pid. This converts
that track to use a struct pid instead of pid_t. This keeps us safe from pid
wrap around issues and prepares the way for the pid namespace.
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/smbfs/proc.c')
-rw-r--r-- | fs/smbfs/proc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/smbfs/proc.c b/fs/smbfs/proc.c index a5ced9e0c6c4..feac46050619 100644 --- a/fs/smbfs/proc.c +++ b/fs/smbfs/proc.c | |||
@@ -877,7 +877,7 @@ smb_newconn(struct smb_sb_info *server, struct smb_conn_opt *opt) | |||
877 | goto out_putf; | 877 | goto out_putf; |
878 | 878 | ||
879 | server->sock_file = filp; | 879 | server->sock_file = filp; |
880 | server->conn_pid = current->pid; | 880 | server->conn_pid = get_pid(task_pid(current)); |
881 | server->opt = *opt; | 881 | server->opt = *opt; |
882 | server->generation += 1; | 882 | server->generation += 1; |
883 | server->state = CONN_VALID; | 883 | server->state = CONN_VALID; |
@@ -971,8 +971,8 @@ smb_newconn(struct smb_sb_info *server, struct smb_conn_opt *opt) | |||
971 | } | 971 | } |
972 | 972 | ||
973 | VERBOSE("protocol=%d, max_xmit=%d, pid=%d capabilities=0x%x\n", | 973 | VERBOSE("protocol=%d, max_xmit=%d, pid=%d capabilities=0x%x\n", |
974 | server->opt.protocol, server->opt.max_xmit, server->conn_pid, | 974 | server->opt.protocol, server->opt.max_xmit, |
975 | server->opt.capabilities); | 975 | pid_nr(server->conn_pid), server->opt.capabilities); |
976 | 976 | ||
977 | /* FIXME: this really should be done by smbmount. */ | 977 | /* FIXME: this really should be done by smbmount. */ |
978 | if (server->opt.max_xmit > SMB_MAX_PACKET_SIZE) { | 978 | if (server->opt.max_xmit > SMB_MAX_PACKET_SIZE) { |