aboutsummaryrefslogtreecommitdiff
path: root/src/device/log.cpp
diff options
context:
space:
mode:
authorCédric <cslashm@gmail.com>2018-03-05 14:46:15 +0100
committercslashm <cslashm@gmail.com>2018-03-12 10:43:06 +0100
commit73dd883d5112e2e8be1a465aca3b3fb48b651afd (patch)
tree612da8e64d9b036f1934174ab766befa9a0324b7 /src/device/log.cpp
parentMerge pull request #3368 (diff)
downloadmonero-73dd883d5112e2e8be1a465aca3b3fb48b651afd.tar.xz
Ledger HW Bug fixes
Fix the way the REAL mode is handle: Let create_transactions_2 and create_transactions_from construct the vector of transactions. Then iterate on it and resign. We just need to add 'outs' list in the TX struct for that. Fix default secret keys value when DEBUG_HWDEVICE mode is off The magic value (00...00 for view key and FF..FF for spend key) was not correctly set when DEBUG_HWDEVICE was off. Both was set to 00...00. Add sub-address info in ABP map in order to correctly display destination sub-address on device Fix DEBUG_HWDEVICE mode: - Fix compilation errors. - Fix control device init in ledger device. - Add more log. Fix sub addr control Fix debug Info
Diffstat (limited to '')
-rw-r--r--src/device/log.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/device/log.cpp b/src/device/log.cpp
index 103b2b3ba..a2ad0f4f4 100644
--- a/src/device/log.cpp
+++ b/src/device/log.cpp
@@ -55,14 +55,14 @@ namespace hw {
MDEBUG(msg << ": " << info);
}
- #ifdef DEBUGLEDGER
+ #ifdef DEBUG_HWDEVICE
extern crypto::secret_key viewkey;
extern crypto::secret_key spendkey;
void decrypt(char* buf, size_t len) {
- #ifdef IODUMMYCRYPT
- int i;
+ #ifdef IODUMMYCRYPT_HWDEVICE
+ size_t i;
if (len == 32) {
//view key?
for (i = 0; i<32; i++) {
@@ -144,7 +144,7 @@ namespace hw {
log_hexbuffer(" device", dd, len);
} else {
- buffer_to_str(logstr, dd, len);
+ buffer_to_str(logstr, 128, dd, len);
log_message("ASSERT EQ OK", msg + ": "+ info + ": "+ std::string(logstr) );
}
}