Initialize variables in non-interactive mode in all cases
The changed handling of thread ids implies that they must be initialized before exit of calcurse where they are used. Hence the function vars_init() is now called irrespective of command line arguments. Signed-off-by: Lars Henriksen <LarsHenriksen@get2net.dk> Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
parent
e9611ce3a6
commit
ddc3fda5f1
@ -730,13 +730,13 @@ int parse_args(int argc, char **argv)
|
|||||||
io_check_dir(path_dir);
|
io_check_dir(path_dir);
|
||||||
io_check_dir(path_notes);
|
io_check_dir(path_notes);
|
||||||
|
|
||||||
|
vars_init();
|
||||||
if (status) {
|
if (status) {
|
||||||
status_arg();
|
status_arg();
|
||||||
} else if (grep) {
|
} else if (grep) {
|
||||||
io_check_file(path_apts);
|
io_check_file(path_apts);
|
||||||
io_check_file(path_todo);
|
io_check_file(path_todo);
|
||||||
io_check_file(path_conf);
|
io_check_file(path_conf);
|
||||||
vars_init();
|
|
||||||
config_load(); /* To get output date format. */
|
config_load(); /* To get output date format. */
|
||||||
io_load_data(&filter);
|
io_load_data(&filter);
|
||||||
if (grep_filter) {
|
if (grep_filter) {
|
||||||
@ -759,7 +759,6 @@ int parse_args(int argc, char **argv)
|
|||||||
io_check_file(path_apts);
|
io_check_file(path_apts);
|
||||||
io_check_file(path_todo);
|
io_check_file(path_todo);
|
||||||
io_check_file(path_conf);
|
io_check_file(path_conf);
|
||||||
vars_init();
|
|
||||||
config_load(); /* To get output date format. */
|
config_load(); /* To get output date format. */
|
||||||
io_load_data(&filter);
|
io_load_data(&filter);
|
||||||
|
|
||||||
@ -786,7 +785,6 @@ int parse_args(int argc, char **argv)
|
|||||||
io_check_file(path_apts);
|
io_check_file(path_apts);
|
||||||
io_check_file(path_todo);
|
io_check_file(path_todo);
|
||||||
/* Get default pager in case we need to show a log file. */
|
/* Get default pager in case we need to show a log file. */
|
||||||
vars_init();
|
|
||||||
io_load_data(NULL);
|
io_load_data(NULL);
|
||||||
if (dump_imported) {
|
if (dump_imported) {
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user