mirror of
https://github.com/tstack/lnav.git
synced 2024-08-17 00:40:30 +03:00
fix -H usage and mem leak
This commit is contained in:
parent
09ee65e917
commit
bd1b90a101
@ -2454,7 +2454,7 @@ SELECT tbl_name FROM sqlite_master WHERE sql LIKE 'CREATE VIRTUAL TABLE%'
|
||||
return print_user_msgs(perform_res);
|
||||
}
|
||||
|
||||
if (!mode_flags.mf_check_configs) {
|
||||
if (!mode_flags.mf_check_configs && !lnav_data.ld_show_help_view) {
|
||||
DEFAULT_FILES.emplace_back("var/log/messages");
|
||||
DEFAULT_FILES.emplace_back("var/log/system.log");
|
||||
DEFAULT_FILES.emplace_back("var/log/syslog");
|
||||
|
@ -1490,7 +1490,9 @@ save_config()
|
||||
|
||||
auto config_str = gen.to_string_fragment().to_string();
|
||||
char errbuf[1024];
|
||||
auto* tree = yajl_tree_parse(config_str.c_str(), errbuf, sizeof(errbuf));
|
||||
auto_mem<yajl_val_s> tree(yajl_tree_free);
|
||||
|
||||
tree = yajl_tree_parse(config_str.c_str(), errbuf, sizeof(errbuf));
|
||||
|
||||
if (tree == nullptr) {
|
||||
return fmt::format(
|
||||
|
Loading…
Reference in New Issue
Block a user