mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-06 01:45:47 +00:00
coverity: #1426028
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
This commit is contained in:
parent
a55f31bda2
commit
a61b4e8584
@ -725,15 +725,9 @@ char *ovl_get_rootfs(const char *rootfs_path, size_t *rootfslen)
|
|||||||
*s3 = '\0';
|
*s3 = '\0';
|
||||||
|
|
||||||
rootfsdir = strdup(s2);
|
rootfsdir = strdup(s2);
|
||||||
if (!rootfsdir) {
|
free(s1);
|
||||||
free(s1);
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!rootfsdir)
|
if (!rootfsdir)
|
||||||
rootfsdir = s1;
|
return NULL;
|
||||||
else
|
|
||||||
free(s1);
|
|
||||||
|
|
||||||
*rootfslen = strlen(rootfsdir);
|
*rootfslen = strlen(rootfsdir);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user