Fix bug related to image import.
This commit is contained in:
parent
1070fe4cc6
commit
4a62d80a7e
@ -2198,9 +2198,9 @@ int iso_image_import(IsoImage *image, IsoDataSource *src,
|
||||
|
||||
/* recursively add image */
|
||||
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;
|
||||
}
|
||||
@ -2252,7 +2252,7 @@ int iso_image_import(IsoImage *image, IsoDataSource *src,
|
||||
iso_image_set_copyright_file_id(image, data->copyright_file_id);
|
||||
iso_image_set_abstract_file_id(image, data->abstract_file_id);
|
||||
iso_image_set_biblio_file_id(image, data->biblio_file_id);
|
||||
|
||||
|
||||
if (features != NULL) {
|
||||
features->hasJoliet = data->joliet;
|
||||
features->hasRR = data->rr_version != 0;
|
||||
|
@ -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