aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2018-12-04 17:31:43 +0200
committerRiccardo Spagni <ric@spagni.net>2018-12-04 17:31:43 +0200
commit0e0777e4d15df9242654235237349aa95587442b (patch)
treea2262fc13a9792e8f8ba261469855e930789816d /src
parentMerge pull request #4885 (diff)
parentcn_deserialize: allow parsing partially valid tx extra (diff)
downloadmonero-0e0777e4d15df9242654235237349aa95587442b.tar.xz
Merge pull request #4888
b0d9d605 cn_deserialize: allow parsing partially valid tx extra (moneromooo-monero)
Diffstat (limited to 'src')
-rw-r--r--src/debug_utilities/cn_deserialize.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/debug_utilities/cn_deserialize.cpp b/src/debug_utilities/cn_deserialize.cpp
index 3e2552230..83422083b 100644
--- a/src/debug_utilities/cn_deserialize.cpp
+++ b/src/debug_utilities/cn_deserialize.cpp
@@ -169,6 +169,7 @@ int main(int argc, char* argv[])
return 1;
}
+ bool full;
cryptonote::block block;
cryptonote::transaction tx;
std::vector<cryptonote::tx_extra_field> fields;
@@ -200,9 +201,9 @@ int main(int argc, char* argv[])
std::cout << "No fields were found in tx_extra" << std::endl;
}
}
- else if (cryptonote::parse_tx_extra(std::vector<uint8_t>(blob.begin(), blob.end()), fields) && !fields.empty())
+ else if (((full = cryptonote::parse_tx_extra(std::vector<uint8_t>(blob.begin(), blob.end()), fields)) || true) && !fields.empty())
{
- std::cout << "Parsed tx_extra:" << std::endl;
+ std::cout << "Parsed" << (full ? "" : " partial") << " tx_extra:" << std::endl;
print_extra_fields(fields);
}
else