message: we want to allow O_PATHed file descriptors
authorDjalal Harouni <tixxdz@opendz.org>
Wed, 22 Oct 2014 14:39:27 +0000 (15:39 +0100)
committerDjalal Harouni <tixxdz@opendz.org>
Wed, 22 Oct 2014 14:39:27 +0000 (15:39 +0100)
Signed-off-by: Djalal Harouni <tixxdz@opendz.org>
message.c

index 1c5f1b023794226df800b78d55f4c5e6e8c45ff8..cb45bc6e4f85bf9c233bf66ba8630f8053881657 100644 (file)
--- a/message.c
+++ b/message.c
@@ -96,7 +96,7 @@ static int kdbus_handle_check_file(struct file *file)
        if (!S_ISSOCK(inode->i_mode))
                return 0;
 
-       if (!(file->f_mode & FMODE_PATH))
+       if (file->f_mode & FMODE_PATH)
                return 0;
 
        sock = SOCKET_I(inode);