aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tun.c
diff options
context:
space:
mode:
authorJeff Layton <jlayton@primarydata.com>2014-08-22 11:27:32 -0400
committerJeff Layton <jlayton@primarydata.com>2014-09-09 16:01:36 -0400
commite0b93eddfe17dcb7d644eb5d6ad02a86fc41a977 (patch)
tree97ceab83fdbfd3bf54fd8235a66da665fbcc83a7 /drivers/net/tun.c
parentlocks: consolidate "nolease" routines (diff)
downloadlinux-dev-e0b93eddfe17dcb7d644eb5d6ad02a86fc41a977.tar.xz
linux-dev-e0b93eddfe17dcb7d644eb5d6ad02a86fc41a977.zip
security: make security_file_set_fowner, f_setown and __f_setown void return
security_file_set_fowner always returns 0, so make it f_setown and __f_setown void return functions and fix up the error handling in the callers. Cc: linux-security-module@vger.kernel.org Signed-off-by: Jeff Layton <jlayton@primarydata.com> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/net/tun.c')
-rw-r--r--drivers/net/tun.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index acaaf6784179..186ce541c657 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -2152,9 +2152,7 @@ static int tun_chr_fasync(int fd, struct file *file, int on)
goto out;
if (on) {
- ret = __f_setown(file, task_pid(current), PIDTYPE_PID, 0);
- if (ret)
- goto out;
+ __f_setown(file, task_pid(current), PIDTYPE_PID, 0);
tfile->flags |= TUN_FASYNC;
} else
tfile->flags &= ~TUN_FASYNC;