kdbus: allow unix domain socket fd passing 54/80254/1 accepted/tizen/common/20160719.172630 accepted/tizen/ivi/20160719.060938 accepted/tizen/mobile/20160719.061003 accepted/tizen/tv/20160719.060929 accepted/tizen/wearable/20160719.060946 submit/tizen/20160719.030401
authorKonrad Lipinski <konrad.l@samsung.com>
Fri, 15 Jul 2016 11:15:05 +0000 (13:15 +0200)
committerKonrad Lipinski <konrad.l@samsung.com>
Fri, 15 Jul 2016 11:15:33 +0000 (13:15 +0200)
Change-Id: Ifafec44da924ec8ed677629606c92a45e7171636

ipc/kdbus/message.c

index 80960756a32994b750c5133cb5e249dffc0cfc42..4b1487a88c49fdd9c28997f35ae9643b7d168499 100644 (file)
@@ -169,9 +169,6 @@ exit:
 
 static int kdbus_handle_check_file(struct file *file)
 {
-       struct inode *inode = file_inode(file);
-       struct socket *sock;
-
        /*
         * Don't allow file descriptors in the transport that themselves allow
         * file descriptor queueing. This will eventually be allowed once both
@@ -181,16 +178,6 @@ static int kdbus_handle_check_file(struct file *file)
        if (file->f_op == &kdbus_handle_ops)
                return -EOPNOTSUPP;
 
-       if (!S_ISSOCK(inode->i_mode))
-               return 0;
-
-       if (file->f_mode & FMODE_PATH)
-               return 0;
-
-       sock = SOCKET_I(inode);
-       if (sock->sk && sock->ops && sock->ops->family == PF_UNIX)
-               return -EOPNOTSUPP;
-
        return 0;
 }