mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
[gnucash-commands.cpp] display report errors to stderr
This commit is contained in:
parent
955043b8c9
commit
15ecf114c6
@ -260,9 +260,9 @@ return a document object with export-string or export-error.") << std::endl;
|
||||
|
||||
if (scm_is_false (id))
|
||||
scm_cleanup_and_exit_with_failure (nullptr);
|
||||
char* html;
|
||||
gnc_run_report (scm_to_int(id), &html);
|
||||
if (html && *html)
|
||||
char *html, *errmsg;
|
||||
|
||||
if (gnc_run_report_with_error_handling (scm_to_int(id), &html, &errmsg))
|
||||
{
|
||||
if (!args->output_file.empty())
|
||||
{
|
||||
@ -273,6 +273,10 @@ return a document object with export-string or export-error.") << std::endl;
|
||||
std::cout << html << std::endl;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
std::cerr << errmsg << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
qof_session_destroy (session);
|
||||
|
Loading…
Reference in New Issue
Block a user