Fixed another bug.

This commit is contained in:
Vreixo Formoso 2008-02-09 02:33:15 +01:00
parent e6593c9738
commit 79158554f1

View File

@ -267,6 +267,7 @@ int filesrc_writer_write_data(IsoImageWriter *writer)
res = filesrc_open(file); res = filesrc_open(file);
name = iso_stream_get_name(file->stream); name = iso_stream_get_name(file->stream);
iso_msg_debug(t->image->id, "Writing file %s", name);
if (res < 0) { if (res < 0) {
/* /*
* UPS, very ugly error, the best we can do is just to write * UPS, very ugly error, the best we can do is just to write
@ -296,9 +297,9 @@ int filesrc_writer_write_data(IsoImageWriter *writer)
filesrc_close(file); filesrc_close(file);
return res; /* aborted due to error severity */ return res; /* aborted due to error severity */
} }
} else {
free(name);
} }
iso_msg_debug(t->image->id, "Writing file %s", name);
free(name);
/* write file contents to image */ /* write file contents to image */
for (b = 0; b < nblocks; ++b) { for (b = 0; b < nblocks; ++b) {