TOCO: Print error message if conversion fails.
PiperOrigin-RevId: 233301060
This commit is contained in:
parent
beccb5be1d
commit
753cb67ab5
@ -49,5 +49,10 @@ int main(int argc, char** argv) {
|
|||||||
}
|
}
|
||||||
toco::port::InitGoogle(argv[0], effective_argc, &effective_argv, true);
|
toco::port::InitGoogle(argv[0], effective_argc, &effective_argv, true);
|
||||||
auto status = toco::Convert(parsed_toco_flags, parsed_model_flags);
|
auto status = toco::Convert(parsed_toco_flags, parsed_model_flags);
|
||||||
return status.ok() ? 0 : -1;
|
if (!status.ok()) {
|
||||||
|
fprintf(stderr, "%s\n", status.error_message().c_str());
|
||||||
|
fflush(stderr);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user