summaryrefslogtreecommitdiff
path: root/lib/http.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/http.js')
-rw-r--r--lib/http.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/http.js b/lib/http.js
index e7e28e816..794af64e8 100644
--- a/lib/http.js
+++ b/lib/http.js
@@ -648,6 +648,9 @@ OutgoingMessage.prototype.addTrailers = function(headers) {
OutgoingMessage.prototype.end = function(data, encoding) {
+ if (this.finished) {
+ return false;
+ }
if (!this._header) {
this._implicitHeader();
}