diff options
author | Lai Jiangshan <laijs@cn.fujitsu.com> | 2008-03-26 12:01:28 +0100 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2008-03-26 12:01:28 +0100 |
commit | 37529fe9f62835e1c11895a1895064748b032dc1 (patch) | |
tree | 961853665601ae08f85008cae589798bdf8f940d /kernel/relay.c | |
parent | Linux 2.6.25-rc7 (diff) | |
download | linux-37529fe9f62835e1c11895a1895064748b032dc1.tar.xz linux-37529fe9f62835e1c11895a1895064748b032dc1.zip |
set relay file can not be read by pread(2)
I found that relay files can be read by pread(2). I fix it,
for relay files are not capable of seeking.
Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to '')
-rw-r--r-- | kernel/relay.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/relay.c b/kernel/relay.c index 4c035a8a248c..ed3f6cf2db86 100644 --- a/kernel/relay.c +++ b/kernel/relay.c @@ -736,7 +736,7 @@ static int relay_file_open(struct inode *inode, struct file *filp) kref_get(&buf->kref); filp->private_data = buf; - return 0; + return nonseekable_open(inode, filp); } /** |