]> git.ipfire.org Git - thirdparty/grub.git/commit
normal/completion: Fix possible NULL pointer dereference
authorPeter Jones <pjones@redhat.com>
Wed, 4 Mar 2020 11:58:44 +0000 (12:58 +0100)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 10 Mar 2020 20:40:23 +0000 (21:40 +0100)
commitf0f97576e02208eb947c8da4bd14c54ea3573109
treef6435d6d1245aa05e1677040e7ab1a44fd31f28b
parent8d88ae92b593d45909d4e03799707eabb98221a7
normal/completion: Fix possible NULL pointer dereference

Coverity Scan reports that the grub_strrchr() function can return NULL if
the character is not found. Check if that's the case for dirfile pointer.

Signed-off-by: Peter Jones <pjones@redhat.com>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/normal/completion.c