coverity: #1426028

parent 7ed560ca
...@@ -722,15 +722,9 @@ char *ovl_get_rootfs(const char *rootfs_path, size_t *rootfslen) ...@@ -722,15 +722,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);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment