You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is this really unreachable or am I missing something? Is there a reason for this code to be there?
Also, given that EXPECT_CHAR already contains CHECK_EOF, and CHECK_EOF doesn't mutate any state, line 207 duplicates line 206, making the routine check for EOF twice in a row, when *buf == '<CR>'.
The text was updated successfully, but these errors were encountered:
Hi
I'm going through the code in order to educate myself on how these parsers work, and I think I've noticed some dead code in
is_complete
function:picohttpparser/picohttpparser.c
Lines 221 to 223 in 81fe3d9
The
while
loop above can only terminate from:CHECK_EOF
in line 206:picohttpparser/picohttpparser.c
Lines 55 to 59 in 81fe3d9
EXPECT_CHAR
, one line below, in line 207:picohttpparser/picohttpparser.c
Lines 61 to 69 in 81fe3d9
picohttpparser/picohttpparser.c
Line 217 in 81fe3d9
Is this really unreachable or am I missing something? Is there a reason for this code to be there?
Also, given that
EXPECT_CHAR
already containsCHECK_EOF
, andCHECK_EOF
doesn't mutate any state, line 207 duplicates line 206, making the routine check for EOF twice in a row, when*buf == '<CR>'
.The text was updated successfully, but these errors were encountered: