diff options
| author | Carl Hetherington <cth@carlh.net> | 2016-07-22 09:20:58 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2016-07-22 09:20:58 +0100 |
| commit | 455475575bcfa30aa60a377235bfaf2fd7bc2da7 (patch) | |
| tree | 691c69e3e25722a4fa6ffe632179243907be8240 /src/decrypted_kdm.cc | |
| parent | 1eb9ba017214698de3fd41de5291604b4fe839c5 (diff) | |
Use locked_sstream. Replace once parse_stream with parse_memory.
Diffstat (limited to 'src/decrypted_kdm.cc')
| -rw-r--r-- | src/decrypted_kdm.cc | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/decrypted_kdm.cc b/src/decrypted_kdm.cc index abe12a32..4ffad923 100644 --- a/src/decrypted_kdm.cc +++ b/src/decrypted_kdm.cc @@ -52,7 +52,6 @@ using std::list; using std::vector; using std::string; -using std::stringstream; using std::setw; using std::setfill; using std::hex; @@ -79,7 +78,7 @@ put_uuid (uint8_t ** d, string id) { id.erase (std::remove (id.begin(), id.end(), '-')); for (int i = 0; i < 32; i += 2) { - stringstream s; + locked_stringstream s; s << id[i] << id[i + 1]; int h; s >> hex >> h; @@ -91,7 +90,7 @@ put_uuid (uint8_t ** d, string id) static string get_uuid (unsigned char ** p) { - stringstream g; + locked_stringstream g; for (int i = 0; i < 16; ++i) { g << setw(2) << setfill('0') << hex << static_cast<int> (**p); @@ -301,7 +300,7 @@ DecryptedKDM::encrypt (shared_ptr<const CertificateChain> signer, Certificate re char out[encrypted_len * 2]; Kumu::base64encode (encrypted, encrypted_len, out, encrypted_len * 2); int const N = strlen (out); - stringstream lines; + locked_stringstream lines; for (int i = 0; i < N; ++i) { if (i > 0 && (i % 64) == 0) { lines << "\n"; |
