diff options
Diffstat (limited to 'net/socket.c')
| -rw-r--r-- | net/socket.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/socket.c b/net/socket.c index 92764d836891..2c730fc718ab 100644 --- a/net/socket.c +++ b/net/socket.c | |||
| @@ -69,7 +69,6 @@ | |||
| 69 | #include <linux/proc_fs.h> | 69 | #include <linux/proc_fs.h> |
| 70 | #include <linux/seq_file.h> | 70 | #include <linux/seq_file.h> |
| 71 | #include <linux/mutex.h> | 71 | #include <linux/mutex.h> |
| 72 | #include <linux/thread_info.h> | ||
| 73 | #include <linux/wanrouter.h> | 72 | #include <linux/wanrouter.h> |
| 74 | #include <linux/if_bridge.h> | 73 | #include <linux/if_bridge.h> |
| 75 | #include <linux/if_frad.h> | 74 | #include <linux/if_frad.h> |
| @@ -491,8 +490,8 @@ static struct socket *sock_alloc(void) | |||
| 491 | sock = SOCKET_I(inode); | 490 | sock = SOCKET_I(inode); |
| 492 | 491 | ||
| 493 | inode->i_mode = S_IFSOCK | S_IRWXUGO; | 492 | inode->i_mode = S_IFSOCK | S_IRWXUGO; |
| 494 | inode->i_uid = current->fsuid; | 493 | inode->i_uid = current_fsuid(); |
| 495 | inode->i_gid = current->fsgid; | 494 | inode->i_gid = current_fsgid(); |
| 496 | 495 | ||
| 497 | get_cpu_var(sockets_in_use)++; | 496 | get_cpu_var(sockets_in_use)++; |
| 498 | put_cpu_var(sockets_in_use); | 497 | put_cpu_var(sockets_in_use); |
| @@ -2307,6 +2306,7 @@ int kernel_accept(struct socket *sock, struct socket **newsock, int flags) | |||
| 2307 | } | 2306 | } |
| 2308 | 2307 | ||
| 2309 | (*newsock)->ops = sock->ops; | 2308 | (*newsock)->ops = sock->ops; |
| 2309 | __module_get((*newsock)->ops->owner); | ||
| 2310 | 2310 | ||
| 2311 | done: | 2311 | done: |
| 2312 | return err; | 2312 | return err; |
