diff options
author | lloyd <[email protected]> | 2007-07-21 19:35:10 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2007-07-21 19:35:10 +0000 |
commit | ad3c9c5a74be828440385f31c4b99affc3f33654 (patch) | |
tree | 77a0d026a9d79469fb0f3c26a430d165061ca9ad /src/pgp_s2k.cpp | |
parent | 5ea451fc8db248c76fe68db87b9c76ffad019655 (diff) |
Use std::string::data() instead of std::string::c_str() in cases where we
just want access to the underlying data representation but don't care if
the return value is NULL terminated or not.
Diffstat (limited to 'src/pgp_s2k.cpp')
-rw-r--r-- | src/pgp_s2k.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pgp_s2k.cpp b/src/pgp_s2k.cpp index 1e2778eea..b8a27cc6e 100644 --- a/src/pgp_s2k.cpp +++ b/src/pgp_s2k.cpp @@ -44,7 +44,7 @@ OctetString OpenPGP_S2K::derive(u32bit key_len, const std::string& passphrase, { hash->update(salt_buf, salt_size); left -= salt_size; - hash->update((const byte*)passphrase.c_str(), left); + hash->update((const byte*)passphrase.data(), left); } hash_buf = hash->final(); |