Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

req.setEncoding "utf8"

  • Loading branch information...
commit cd8b96f6bd037d104036101bedc65f05bc309055 1 parent 2192fb4
@rsms authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  connect_json.mv
View
1  connect_json.mv
@@ -28,6 +28,7 @@ connect_json = ^(req, res, next) {
}
if (ct && ct.indexOf('application/json') == 0) {
buffer = ''
+ req.setEncoding 'utf8'
req.on 'data', ^(chunk) {
if (buffer.length + chunk.length > length) {
# Kill the connection on suspected buffer overflow attempt
Please sign in to comment.
Something went wrong with that request. Please try again.