add:   if (this.isClosed) return Components.results.NS_BASE_STREAM_CLOSED;  
context: function sp_datawrite (request, ctxt, ostream, offset, count){    if (!this.pendingData)    {        this.isBlocked = true;        /* this is here to support pre-XPCDOM builds (0.9.0 era), which         * don't have this result code mapped. */        if (!Components.results.NS_BASE_STREAM_WOULD_BLOCK)            throw 2152136711;                throw Components.results.NS_BASE_STREAM_WOULD_BLOCK;    }        var len = ostream.write (this.pendingData, this.pendingData.length);    this.pendingData = this.pendingData.substr (len);}
meta: 5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5872/27364ee9ed40a24f7477a7f212d3113ebc57051d/connection-xpcom.js/clean/extensions/irc/js/lib/connection-xpcom.js