refactor: Use SpanReader over DataStream

The mutable temporary strValue can be re-used to apply the obfuscation,
which allows to avoid a redundant copy of the value.
This commit is contained in:
MarcoFalke committed 2026-02-02 18:42:44 +01:00
1 parent fa06e26764
commit fad3eb3956
1 file changed
+2 -2
+2 -2
View File
@@ -214,9 +214,9 @@ public:
return false; return false;
} }
try { try {
DataStream ssValue{MakeByteSpan(*strValue)}; std::span ssValue{MakeWritableByteSpan(*strValue)};
m_obfuscation(ssValue); m_obfuscation(ssValue);
ssValue >> value; SpanReader{ssValue} >> value;
} catch (const std::exception&) { } catch (const std::exception&) {
return false; return false;
} }