From 142e5e1eb47812c04a7623de7a8821726a1f1789 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sun, 12 Feb 2017 18:35:54 +0000 Subject: tools: set requested log level also move a couple logs from INFO to DEBUG --- src/blockchain_utilities/blockchain_export.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/blockchain_utilities/blockchain_export.cpp') diff --git a/src/blockchain_utilities/blockchain_export.cpp b/src/blockchain_utilities/blockchain_export.cpp index b4411fbba..13016b11b 100644 --- a/src/blockchain_utilities/blockchain_export.cpp +++ b/src/blockchain_utilities/blockchain_export.cpp @@ -126,6 +126,7 @@ int main(int argc, char* argv[]) block_stop = command_line::get_arg(vm, arg_block_stop); mlog_configure("monero-blockchain-export", true); + mlog_set_log(std::string(std::to_string(log_level) + ",bcutil:INFO").c_str()); LOG_PRINT_L0("Starting..."); bool opt_testnet = command_line::get_arg(vm, arg_testnet_on); -- cgit v1.2.3 From 882db8e9d9414a4bc705a9252d4d2525b454eec3 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sun, 12 Feb 2017 19:36:52 +0000 Subject: tools: log to the correct file --- src/blockchain_utilities/blockchain_export.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/blockchain_utilities/blockchain_export.cpp') diff --git a/src/blockchain_utilities/blockchain_export.cpp b/src/blockchain_utilities/blockchain_export.cpp index 13016b11b..56f6d9485 100644 --- a/src/blockchain_utilities/blockchain_export.cpp +++ b/src/blockchain_utilities/blockchain_export.cpp @@ -57,6 +57,8 @@ std::string join_set_strings(const std::unordered_set& db_types_all int main(int argc, char* argv[]) { + epee::string_tools::set_module_name_and_folder(argv[0]); + std::string default_db_type = "lmdb"; std::unordered_set db_types_all = cryptonote::blockchain_db_types; @@ -125,7 +127,7 @@ int main(int argc, char* argv[]) log_level = command_line::get_arg(vm, arg_log_level); block_stop = command_line::get_arg(vm, arg_block_stop); - mlog_configure("monero-blockchain-export", true); + mlog_configure(mlog_get_default_log_path("monero-blockchain-export.log"), true); mlog_set_log(std::string(std::to_string(log_level) + ",bcutil:INFO").c_str()); LOG_PRINT_L0("Starting..."); -- cgit v1.2.3