]> git.ipfire.org Git - thirdparty/grub.git/commit
Revert "zfsinfo: Correct a check for error allocating memory"
authorVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Fri, 6 Oct 2023 18:23:53 +0000 (20:23 +0200)
committerDaniel Kiper <daniel.kiper@oracle.com>
Thu, 12 Oct 2023 17:28:33 +0000 (19:28 +0200)
commit4e10213de66aae53c9292038ff6b8b6ae3d1ed6a
tree11e5be8af8c5b7a3e7ddf136d792d8dffccf69df
parent4266fd2bb2f2872a442c2565aba7f7835c50fa2a
Revert "zfsinfo: Correct a check for error allocating memory"

Original commit is wrong because grub_file_get_device_name() may return NULL
if we use implicit $root. Additionally, the grub_errno is guaranteed to be
GRUB_ERR_NONE at the beginning of a command. So, everything should work as
expected and Coverity report, CID 73668, WRT to this code should be treated
as false positive.

This reverts commit 7aab03418 (zfsinfo: Correct a check for error allocating memory).

Fixes: 7aab03418 (zfsinfo: Correct a check for error allocating memory)
Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/fs/zfs/zfsinfo.c