Skip to content

Commit 4e49da5

Browse files
committed
Use correct unique_ptr types for document and array values
1 parent 7a8b689 commit 4e49da5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/bsoncxx/array/value.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ namespace array {
3434
class BSONCXX_API value {
3535
public:
3636
using deleter_type = void (*)(std::uint8_t*);
37-
using unique_ptr_type = std::unique_ptr<uint8_t, deleter_type>;
37+
using unique_ptr_type = std::unique_ptr<uint8_t[], deleter_type>;
3838

3939
///
4040
/// Constructs a value from a buffer.

src/bsoncxx/document/value.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ namespace document {
3333
class BSONCXX_API value {
3434
public:
3535
using deleter_type = void (*)(std::uint8_t*);
36-
using unique_ptr_type = std::unique_ptr<uint8_t, deleter_type>;
36+
using unique_ptr_type = std::unique_ptr<uint8_t[], deleter_type>;
3737

3838
///
3939
/// Constructs a value from a buffer.

0 commit comments

Comments
 (0)