mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Fix coverity defects: CID 147511, 147513
CID 147511: Type:Dereference before null check CID 147513: Type:Dereference before null check Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: cao.xuewen <cao.xuewen@zte.com.cn> Closes #5306
This commit is contained in:
+1
-1
@@ -3290,7 +3290,7 @@ zdb_vdev_lookup(vdev_t *vdev, char *path)
|
||||
return (NULL);
|
||||
|
||||
vdev = vdev->vdev_child[i];
|
||||
if (*s == '\0')
|
||||
if (s && *s == '\0')
|
||||
return (vdev);
|
||||
return (zdb_vdev_lookup(vdev, s+1));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user