diff options
Diffstat (limited to 'coding')
-rw-r--r-- | coding/file_container.cpp | 8 | ||||
-rw-r--r-- | coding/file_container.hpp | 1 |
2 files changed, 8 insertions, 1 deletions
diff --git a/coding/file_container.cpp b/coding/file_container.cpp index 2598fa299a..69d4a698f7 100644 --- a/coding/file_container.cpp +++ b/coding/file_container.cpp @@ -440,7 +440,13 @@ void FilesContainerW::Write(ModelReaderPtr reader, Tag const & tag) void FilesContainerW::Write(vector<char> const & buffer, Tag const & tag) { if (!buffer.empty()) - GetWriter(tag).Write(&buffer[0], buffer.size()); + GetWriter(tag).Write(buffer.data(), buffer.size()); +} + +void FilesContainerW::Write(vector<uint8_t> const & buffer, Tag const & tag) +{ + if (!buffer.empty()) + GetWriter(tag).Write(buffer.data(), buffer.size()); } void FilesContainerW::Finish() diff --git a/coding/file_container.hpp b/coding/file_container.hpp index 01e3fd8c0e..1307e8e8cd 100644 --- a/coding/file_container.hpp +++ b/coding/file_container.hpp @@ -238,6 +238,7 @@ public: void Write(string const & fPath, Tag const & tag); void Write(ModelReaderPtr reader, Tag const & tag); void Write(vector<char> const & buffer, Tag const & tag); + void Write(vector<uint8_t> const & buffer, Tag const & tag); void Finish(); |