mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-20 23:36:20 +00:00
IfcConvert: proper "exit routine" if initialization of input fails when trying to create geometry files.
This commit is contained in:
committed by
Thomas Krijnen
parent
c420cc1abb
commit
2024a24e31
@@ -595,6 +595,7 @@ int main(int argc, char** argv)
|
|||||||
|
|
||||||
if (use_element_hierarchy && output_extension != ".dae") {
|
if (use_element_hierarchy && output_extension != ".dae") {
|
||||||
std::cerr << "[Error] --use-element-hierarchy can be used only with .dae output.\n";
|
std::cerr << "[Error] --use-element-hierarchy can be used only with .dae output.\n";
|
||||||
|
/// @todo Lots of duplicate error-and-exit code.
|
||||||
write_log(!quiet);
|
write_log(!quiet);
|
||||||
print_usage();
|
print_usage();
|
||||||
delete serializer;
|
delete serializer;
|
||||||
@@ -628,6 +629,9 @@ int main(int argc, char** argv)
|
|||||||
time(&start);
|
time(&start);
|
||||||
|
|
||||||
if (!init_input_file(input_filename, ifc_file, no_progress || quiet, mmap)) {
|
if (!init_input_file(input_filename, ifc_file, no_progress || quiet, mmap)) {
|
||||||
|
write_log(!quiet);
|
||||||
|
delete serializer;
|
||||||
|
std::remove(output_temp_filename.c_str()); /**< @todo Windows Unicode support */
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user