Fix bug related to image import.
This commit is contained in:
parent
1070fe4cc6
commit
4a62d80a7e
@ -2200,7 +2200,7 @@ int iso_image_import(IsoImage *image, IsoDataSource *src,
|
||||
ret = iso_add_dir_src_rec(image, image->root, newroot);
|
||||
|
||||
/* error during recursive image addition? */
|
||||
if (ret <= 0) {
|
||||
if (ret < 0) {
|
||||
iso_node_builder_unref(image->builder);
|
||||
goto import_revert;
|
||||
}
|
||||
|
@ -491,7 +491,7 @@ int check_special(IsoImage *image, mode_t mode)
|
||||
* Recursively add a given directory to the image tree.
|
||||
*
|
||||
* @return
|
||||
* 1 continue, 0 stop, < 0 error
|
||||
* 1 continue, < 0 error (ISO_CANCELED stop)
|
||||
*/
|
||||
int iso_add_dir_src_rec(IsoImage *image, IsoDir *parent, IsoFileSource *dir)
|
||||
{
|
||||
@ -608,7 +608,7 @@ dir_rec_continue:;
|
||||
} /* while */
|
||||
|
||||
iso_file_source_close(dir);
|
||||
return ret;
|
||||
return ret < 0 ? ret : ISO_SUCCESS;
|
||||
}
|
||||
|
||||
int iso_tree_add_dir_rec(IsoImage *image, IsoDir *parent, const char *dir)
|
||||
|
Loading…
Reference in New Issue
Block a user