Re: [PATCH] drbd:fix null pointer deref in _drbd_md_sync_page_io

2017-04-26 Thread Lars Ellenberg
On Wed, Apr 26, 2017 at 02:49:37AM -0700, Heloise wrote: > The return value of bio_alloc_drbd can be NULL and is used without No, apparently it cannot, because it is basically a mempool_alloc() with GFP_NOIO, it may sleep, but it will loop "forever" and not return NULL. So rather fix that nonsens

[PATCH] drbd:fix null pointer deref in _drbd_md_sync_page_io

2017-04-26 Thread Heloise
The return value of bio_alloc_drbd can be NULL and is used without validation, which may cause null-pointer dereference, fix it. Signed-off-by: Heloise --- drivers/block/drbd/drbd_actlog.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/block/drbd/drbd_actlog.c b/drivers/block/dr