mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-05 16:00:05 +01:00
Fix type mistake in blkid_handle allocation.
This commit is contained in:
committed by
Milan Broz
parent
1b9148f12f
commit
fe3ef6fc2e
@@ -87,7 +87,7 @@ int blk_init_by_path(struct blkid_handle **h, const char *path)
|
||||
{
|
||||
int r = -ENOTSUP;
|
||||
#ifdef HAVE_BLKID
|
||||
struct blkid_handle *tmp = malloc(sizeof(*h));
|
||||
struct blkid_handle *tmp = malloc(sizeof(*tmp));
|
||||
if (!tmp)
|
||||
return -ENOMEM;
|
||||
|
||||
@@ -110,7 +110,7 @@ int blk_init_by_fd(struct blkid_handle **h, int fd)
|
||||
{
|
||||
int r = -ENOTSUP;
|
||||
#ifdef HAVE_BLKID
|
||||
struct blkid_handle *tmp = malloc(sizeof(*h));
|
||||
struct blkid_handle *tmp = malloc(sizeof(*tmp));
|
||||
if (!tmp)
|
||||
return -ENOMEM;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user