- From: Yutaka Hirano <notifications@github.com>
- Date: Wed, 10 Dec 2014 20:56:44 -0800
- To: whatwg/streams <streams@noreply.github.com>
Received on Thursday, 11 December 2014 04:57:22 UTC
> + return this._stream.read(...args); > + } finally { > + this._setReader(this._stream, this); > + } > + } > + > + cancel(reason, ...args) { > + EnsureStreamReaderIsExclusive(this); > + > + var stream = this._stream; > + this.releaseLock(); > + return stream.cancel(reason, ...args); > + } > + > + releaseLock() { > + this._setReader(this._stream, undefined); We need check here, otherwise someone can release a lock with another already-released reader object. --- Reply to this email directly or view it on GitHub: https://github.com/whatwg/streams/pull/251/files#r21658101
Received on Thursday, 11 December 2014 04:57:22 UTC