aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/wallet/wallet_args.cpp5
-rw-r--r--tests/unit_tests/blockchain_db.cpp4
2 files changed, 6 insertions, 3 deletions
diff --git a/src/wallet/wallet_args.cpp b/src/wallet/wallet_args.cpp
index a4bb342ca..9da9d109c 100644
--- a/src/wallet/wallet_args.cpp
+++ b/src/wallet/wallet_args.cpp
@@ -206,7 +206,10 @@ namespace wallet_args
if (!command_line::is_arg_defaulted(vm, arg_log_level))
MINFO("Setting log level = " << command_line::get_arg(vm, arg_log_level));
else
- MINFO("Setting log levels = " << getenv("MONERO_LOGS"));
+ {
+ const char *logs = getenv("MONERO_LOGS");
+ MINFO("Setting log levels = " << (logs ? logs : "<default>"));
+ }
MINFO(wallet_args::tr("Logging to: ") << log_path);
Print(print) << boost::format(wallet_args::tr("Logging to %s")) % log_path;
diff --git a/tests/unit_tests/blockchain_db.cpp b/tests/unit_tests/blockchain_db.cpp
index f302d7946..d7c60cecb 100644
--- a/tests/unit_tests/blockchain_db.cpp
+++ b/tests/unit_tests/blockchain_db.cpp
@@ -162,7 +162,7 @@ protected:
{
block bl;
blobdata bd = h2b(i);
- parse_and_validate_block_from_blob(bd, bl);
+ CHECK_AND_ASSERT_THROW_MES(parse_and_validate_block_from_blob(bd, bl), "Invalid block");
m_blocks.push_back(std::make_pair(bl, bd));
}
for (auto& i : t_transactions)
@@ -172,7 +172,7 @@ protected:
{
transaction tx;
blobdata bd = h2b(j);
- parse_and_validate_tx_from_blob(bd, tx);
+ CHECK_AND_ASSERT_THROW_MES(parse_and_validate_tx_from_blob(bd, tx), "Invalid transaction");
txs.push_back(std::make_pair(tx, bd));
}
m_txs.push_back(txs);