aboutsummaryrefslogtreecommitdiff
path: root/src/script.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/script.h')
-rw-r--r--src/script.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/script.h b/src/script.h
index bd6574627a..ea988f0e40 100644
--- a/src/script.h
+++ b/src/script.h
@@ -770,12 +770,12 @@ public:
void Serialize(Stream &s, int nType, int nVersion) const {
std::vector<unsigned char> compr;
if (Compress(compr)) {
- s << CFlatData(&compr[0], &compr[compr.size()]);
+ s << CFlatData(compr);
return;
}
unsigned int nSize = script.size() + nSpecialScripts;
s << VARINT(nSize);
- s << CFlatData(&script[0], &script[script.size()]);
+ s << CFlatData(script);
}
template<typename Stream>
@@ -784,13 +784,13 @@ public:
s >> VARINT(nSize);
if (nSize < nSpecialScripts) {
std::vector<unsigned char> vch(GetSpecialSize(nSize), 0x00);
- s >> REF(CFlatData(&vch[0], &vch[vch.size()]));
+ s >> REF(CFlatData(vch));
Decompress(nSize, vch);
return;
}
nSize -= nSpecialScripts;
script.resize(nSize);
- s >> REF(CFlatData(&script[0], &script[script.size()]));
+ s >> REF(CFlatData(script));
}
};