diff options
-rw-r--r-- | src/cryptonote_core/cryptonote_format_utils.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cryptonote_core/cryptonote_format_utils.cpp b/src/cryptonote_core/cryptonote_format_utils.cpp index b5f2b069d..e04409d87 100644 --- a/src/cryptonote_core/cryptonote_format_utils.cpp +++ b/src/cryptonote_core/cryptonote_format_utils.cpp @@ -371,6 +371,8 @@ namespace cryptonote //--------------------------------------------------------------- bool remove_field_from_tx_extra(std::vector<uint8_t>& tx_extra, const std::type_info &type) { + if (tx_extra.empty()) + return true; std::string extra_str(reinterpret_cast<const char*>(tx_extra.data()), tx_extra.size()); std::istringstream iss(extra_str); binary_archive<false> ar(iss); |