zfs: fix memory leak

Found by: Coverity scan.
CID: 73647
This commit is contained in:
Andrei Borzenkov 2015-06-19 20:47:43 +03:00
parent 4db569ca6a
commit fbdd37e7f9

View file

@ -2882,7 +2882,10 @@ dnode_get_path (struct subvolume *subvol, const char *path_in, dnode_end_t *dn,
err = dmu_read (&(dnode_path->dn), block, &t, 0, data); err = dmu_read (&(dnode_path->dn), block, &t, 0, data);
if (err) if (err)
return err; {
grub_free (sym_value);
return err;
}
movesize = sym_sz - block * blksz; movesize = sym_sz - block * blksz;
if (movesize > blksz) if (movesize > blksz)