direct-io: fix use after free
PATCH 1/1 direct-io: fix use after free
Signed-off-by Kent Overstreet <[email protected]>
--- fs/direct-io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/direct-io.c +1 -1
@@ -472,8 +472,8 @@ static int dio_bio_complete(struct dio *dio, struct bio *bio) dio->io_error = -EIO ;if (dio->is_async && dio->rw ==READ && dio->should_dirty) { -bio_check_pages_dirty (bio);/* transfers ownership */ err = bio->bi_error; +bio_check_pages_dirty (bio);/* transfers ownership */ }else {bio_for_each_segment_all (bvec, bio, i) {struct page *page = bvec->bv_page;
Signature · 1 line
2.7.0
PATCH 1/1 direct-io: fix use after free
Hi,
i've sent exactly the same fix a while ago in the linux-block, here it is:
https://lkml.org/lkml/2016/1/30/146
Quoted 26 lines · Kent Overstreet
Signed-off-by Kent Overstreet <[email protected]>--- fs/direct-io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/direct-io.c +1
-1@@ -472,8 +472,8 @@ static int dio_bio_complete(struct dio *dio, struct bio *bio) dio->io_error = -EIO ;if (dio->is_async && dio->rw ==READ && dio->should_dirty) { -bio_check_pages_dirty (bio);/* transfers ownership */ err = bio->bi_error; +bio_check_pages_dirty (bio);/* transfers ownership */ }else {bio_for_each_segment_all (bvec, bio, i) {struct page *page = bvec->bv_page;Signature · 6 lines
2.7.0 -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html