From: Blazej Adamczyk <blazej.adamczyk@gmail.com>
To: 13598@debbugs.gnu.org
Subject: bug#13598: 24.3.50;
Date: Wed, 26 Feb 2014 10:32:45 +0100 [thread overview]
Message-ID: <5007F097-0E1C-42DE-BD66-56BED0D9C28B@gmail.com> (raw)
In-Reply-To: <87d2wluuu9.fsf@online.de>
Hello,
I had to reopen the bug because I faced the same problem as OP. His didn't make himself clear:
By example:
When parsing response we may get in state when we will receive only the following:
"HTTP/1.0 200 OK^M
"
without double quotes (I added them to show the newline character).
In case of current implementation the regexp "^\r?$" and the previous regexp "^\r*$" both are matching the end of string. That is wrong because there will be something in the new line after a while.
RFC 2616 states clear:
generic-message = start-line
*(message-header CRLF)
CRLF
[ message-body ]
start-line = Request-Line | Status-Line
there has to be one (exactly one) CR in a single line between headers and body. Thus I propose a simple regexp "^\r$".
--
Blazej
next prev parent reply other threads:[~2014-02-26 9:32 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-31 17:26 bug#13598: 24.3.50; url-http.el doesn't correctly parse headers when they are sent line-by-line Jonas Hoersch
2013-02-07 18:13 ` Jonas Hörsch
2013-02-13 17:19 ` Bastien
2013-02-13 19:30 ` Stefan Monnier
2013-02-13 19:42 ` Glenn Morris
2013-02-13 21:38 ` Glenn Morris
2013-02-14 6:08 ` Bastien
2013-02-16 2:06 ` Glenn Morris
2014-02-26 9:32 ` Blazej Adamczyk [this message]
2014-02-26 16:54 ` bug#13598: 24.3.50 Blazej Adamczyk
2014-02-27 22:43 ` Glenn Morris
2014-03-03 6:10 ` Blazej Adamczyk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5007F097-0E1C-42DE-BD66-56BED0D9C28B@gmail.com \
--to=blazej.adamczyk@gmail.com \
--cc=13598@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.