Bob Peterson a6b1752469 gfs2: check for empty rgrp tree in gfs2_ri_update
commit 778721510e84209f78e31e2ccb296ae36d623f5e upstream.

If gfs2 tries to mount a (corrupt) file system that has no resource
groups it still tries to set preferences on the first one, which causes
a kernel null pointer dereference. This patch adds a check to function
gfs2_ri_update so this condition is detected and reported back as an
error.

Reported-by: syzbot+e3f23ce40269a4c9053a@syzkaller.appspotmail.com
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-12-11 13:38:01 +01:00
..
2016-05-12 22:28:05 -04:00
2016-06-27 09:47:09 -05:00
2016-06-27 09:47:08 -05:00
2018-05-30 07:50:47 +02:00
2016-06-27 09:47:09 -05:00
2017-07-12 15:01:06 +02:00
2016-08-02 12:05:27 -05:00
2016-06-07 13:41:38 -06:00
2016-06-07 13:41:38 -06:00
2015-12-06 21:25:17 -05:00