Alain Knaff 5b6f1eb97d vfs: lseek(fd, 0, SEEK_CUR) race condition
This patch fixes a race condition in lseek. While it is expected that
unpredictable behaviour may result while repositioning the offset of a
file descriptor concurrently with reading/writing to the same file
descriptor, this should not happen when merely *reading* the file
descriptor's offset.

Unfortunately, the only portable way in Unix to read a file
descriptor's offset is lseek(fd, 0, SEEK_CUR); however executing this
concurrently with read/write may mess up the position.

[with fixes from akpm]

Signed-off-by: Alain Knaff <alain@knaff.lu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2009-01-05 11:53:07 -05:00
..
2008-12-25 11:40:09 +11:00
2008-10-31 00:56:28 -07:00
2008-11-14 11:29:12 +11:00
2008-12-31 18:07:43 -05:00
2008-11-20 08:11:52 +11:00
2008-08-20 15:40:32 -07:00
2008-10-13 09:47:43 +11:00
2008-11-25 16:51:45 -08:00
2008-12-31 18:07:43 -05:00
2008-12-31 18:07:44 -05:00
2008-12-31 18:07:44 -05:00
2008-11-14 10:39:25 +11:00
2008-12-31 18:07:44 -05:00
2008-12-30 16:51:43 -05:00
2008-12-30 16:51:43 -05:00
2008-12-30 16:51:43 -05:00
2008-10-17 02:38:36 +11:00
2008-12-01 19:55:25 -08:00
2008-11-18 15:08:56 +01:00
2008-12-31 18:07:44 -05:00
2008-12-04 17:16:36 +11:00
2008-12-29 16:47:18 +11:00
2008-12-29 08:29:50 +01:00
2008-12-31 18:07:43 -05:00
2009-01-03 11:45:54 -08:00
2008-12-29 08:29:53 +01:00
2008-10-23 05:12:59 -04:00
2008-12-31 18:07:38 -05:00
2008-12-25 11:40:09 +11:00
2008-12-31 18:07:43 -05:00
2008-10-30 11:38:45 -07:00
2008-12-31 18:07:41 -05:00
2008-10-30 11:38:45 -07:00