Bug 1789403 - Implement the size() method in our OTSStream subclass. r=RyanVM

Depends on D156858

Differential Revision: https://phabricator.services.mozilla.com/D156859
This commit is contained in:
Jonathan Kew 2022-09-10 16:10:38 +00:00
Родитель 9c5dc173c9
Коммит e1a7792795
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -35,6 +35,8 @@ class gfxOTSExpandingMemoryStream : public ots::OTSStream {
~gfxOTSExpandingMemoryStream() { mAlloc.Free(mPtr); }
size_t size() override { return mLimit; }
// Return the buffer, resized to fit its contents (as it may have been
// over-allocated during growth), and give up ownership of it so the
// caller becomes responsible to call free() when finished with it.