mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-11-11 02:53:48 +01:00
Set log level earlier
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
This commit is contained in:
parent
f5983a8429
commit
03e1fb1f90
18
main.c
18
main.c
@ -85,6 +85,15 @@ main(int argc, char* argv[])
|
||||
}
|
||||
g_option_context_free(context);
|
||||
|
||||
/* Set log level. */
|
||||
if (loglevel == NULL || g_strcmp0(loglevel, "info") == 0) {
|
||||
girara_set_debug_level(GIRARA_INFO);
|
||||
} else if (g_strcmp0(loglevel, "warning") == 0) {
|
||||
girara_set_debug_level(GIRARA_WARNING);
|
||||
} else if (g_strcmp0(loglevel, "error") == 0) {
|
||||
girara_set_debug_level(GIRARA_ERROR);
|
||||
}
|
||||
|
||||
if (synctex_fwd != NULL) {
|
||||
if (argc != 2) {
|
||||
girara_error(_("Too many arguments or missing filename while running with --syntex-forward"));
|
||||
@ -109,15 +118,6 @@ main(int argc, char* argv[])
|
||||
setsid();
|
||||
}
|
||||
|
||||
/* Set log level. */
|
||||
if (loglevel == NULL || g_strcmp0(loglevel, "info") == 0) {
|
||||
girara_set_debug_level(GIRARA_INFO);
|
||||
} else if (g_strcmp0(loglevel, "warning") == 0) {
|
||||
girara_set_debug_level(GIRARA_WARNING);
|
||||
} else if (g_strcmp0(loglevel, "error") == 0) {
|
||||
girara_set_debug_level(GIRARA_ERROR);
|
||||
}
|
||||
|
||||
zathura_set_xid(zathura, embed);
|
||||
zathura_set_config_dir(zathura, config_dir);
|
||||
zathura_set_data_dir(zathura, data_dir);
|
||||
|
Loading…
Reference in New Issue
Block a user