diff options
Diffstat (limited to 'src/mongo/bson/stringdata.h')
-rw-r--r-- | src/mongo/bson/stringdata.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/bson/stringdata.h b/src/mongo/bson/stringdata.h index 1fb4e7d25d3..f8a56c1ba2f 100644 --- a/src/mongo/bson/stringdata.h +++ b/src/mongo/bson/stringdata.h @@ -42,14 +42,14 @@ namespace mongo { /** Construct a StringData explicitly, for the case where the length of the string * is already known. 'c' must be a pointer to a null-terminated string, and strlenOfc - * must be the length that std::strlen(c) would return, a.k.a the index of the + * must be the length that strlen(c) would return, a.k.a the index of the * terminator in c. */ StringData( const char* c, unsigned len ) : _data(c), _size(len) {} - /** Construct a StringData, for the case of a std::string. */ - StringData( const string& s ) + /** Construct a StringData, for the case of a string. */ + StringData( const std::string& s ) : _data(s.c_str()), _size((unsigned) s.size()) {} // Construct a StringData explicitly, for the case of a literal whose size is |