Bug 1759572 - AsyncLengthWaitHelper should be threadsafe, r=asuth

This works only because the only implementation of nsIAsyncInputStreamLength
happened to only run on the current thread. Bug 1754004, changes this, and requires the reference to be threadsafe.

Differential Revision: https://phabricator.services.mozilla.com/D141037
This commit is contained in:
Nika Layzell 2022-05-02 20:44:21 +00:00
Родитель c5140538b7
Коммит fd60df03b9
1 изменённых файлов: 2 добавлений и 4 удалений

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

@ -1276,11 +1276,9 @@ nsMultiplexInputStream::Length(int64_t* aLength) {
}
class nsMultiplexInputStream::AsyncWaitLengthHelper final
: public nsIInputStreamLengthCallback
{
: public nsIInputStreamLengthCallback {
public:
NS_DECL_ISUPPORTS
NS_DECL_THREADSAFE_ISUPPORTS
AsyncWaitLengthHelper()
: mStreamNotified(false), mLength(0), mNegativeSize(false) {}