Please tell me this is no longer valid?!

243 views
Skip to first unread message

Kevin Ingwersen (Ingwie Phoenix)

unread,
Jan 13, 2015, 10:15:56 AM1/13/15
to nod...@googlegroups.com
So while working on a FCGI thing, I came across a very, very weird if statement:

try {
var parsed = htparser.execute(buffer, start, len);
console.log("-> Parsed message:",parsed);
if(parsed.message == "Parse Error" && ("bytesParsed" in parsed)) {
_current.resp.write(buffer.slice(start + parsed.bytesParsed, start + len));
}
}
catch(ex) {
_current.cb(ex);
}

This looked so off, that I added this console.log statement to read whats up. Result:

-> Parsed message: { [Error: Parse Error] bytesParsed: 0, code: 'HPE_INVALID_METHOD‘ }

So I went and traced this error constant…and found:


Good lord, please tell me this is no longer true? If so, this is rather embarrassing… xD

Kind regards, Ingwie

Will Hoover

unread,
Jan 13, 2015, 11:36:18 AM1/13/15
to nod...@googlegroups.com

For more info see:

 

https://github.com/joyent/http-parser/pull/156

 

From: Will Hoover [mailto:js.wh...@gmail.com]
Sent: Tuesday, January 13, 2015 11:00 AM
To: 'nod...@googlegroups.com'
Subject: RE: [nodejs] Please tell me this is no longer valid?!

 

Unfortunately, I think it's still the case:

 

https://github.com/joyent/http-parser/pull/158

--
Job board: http://jobs.nodejs.org/
New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
To post to this group, send email to nod...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/D075073A-7411-4E79-80D4-7C5F00E3DD6A%40googlemail.com.
For more options, visit https://groups.google.com/d/optout.

Will Hoover

unread,
Jan 13, 2015, 11:36:41 AM1/13/15
to nod...@googlegroups.com

Unfortunately, I think it's still the case:

 

https://github.com/joyent/http-parser/pull/158

 

From: nod...@googlegroups.com [mailto:nod...@googlegroups.com] On Behalf Of Kevin Ingwersen (Ingwie Phoenix)


Sent: Tuesday, January 13, 2015 10:11 AM
To: nod...@googlegroups.com

--

Reply all
Reply to author
Forward
0 new messages