aboutsummaryrefslogtreecommitdiff
path: root/src/serialization/pair.h
diff options
context:
space:
mode:
authorluigi1111 <luigi1111w@gmail.com>2021-06-10 12:00:54 -0500
committerluigi1111 <luigi1111w@gmail.com>2021-06-10 12:00:54 -0500
commit7499837a6fe8d3533e1360dce8f3ba230ff76042 (patch)
treecd3e089e2e09de33044220ff72461a761b028e3f /src/serialization/pair.h
parentMerge pull request #7729 (diff)
parentImprove cryptonote (block and tx) binary read performance (diff)
downloadmonero-7499837a6fe8d3533e1360dce8f3ba230ff76042.tar.xz
Merge pull request #7661
08e4497 Improve cryptonote (block and tx) binary read performance (Lee Clagett)
Diffstat (limited to 'src/serialization/pair.h')
-rw-r--r--src/serialization/pair.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/serialization/pair.h b/src/serialization/pair.h
index 44aafa04d..2d9a89242 100644
--- a/src/serialization/pair.h
+++ b/src/serialization/pair.h
@@ -69,19 +69,19 @@ inline bool do_serialize(Archive<false>& ar, std::pair<F,S>& p)
{
size_t cnt;
ar.begin_array(cnt);
- if (!ar.stream().good())
+ if (!ar.good())
return false;
if (cnt != 2)
return false;
if (!::serialization::detail::serialize_pair_element(ar, p.first))
return false;
- if (!ar.stream().good())
+ if (!ar.good())
return false;
ar.delimit_array();
if (!::serialization::detail::serialize_pair_element(ar, p.second))
return false;
- if (!ar.stream().good())
+ if (!ar.good())
return false;
ar.end_array();
@@ -92,16 +92,16 @@ template <template <bool> class Archive, class F, class S>
inline bool do_serialize(Archive<true>& ar, std::pair<F,S>& p)
{
ar.begin_array(2);
- if (!ar.stream().good())
+ if (!ar.good())
return false;
if(!::serialization::detail::serialize_pair_element(ar, p.first))
return false;
- if (!ar.stream().good())
+ if (!ar.good())
return false;
ar.delimit_array();
if(!::serialization::detail::serialize_pair_element(ar, p.second))
return false;
- if (!ar.stream().good())
+ if (!ar.good())
return false;
ar.end_array();
return true;