changeset 74012:4e7c6f1faddf

(url-http-wait-for-headers-change-function): Defer detection of HTTP 0.9 until we have at least one line.
author Magnus Henoch <mange@freemail.hu>
date Wed, 15 Nov 2006 23:07:11 +0000
parents cce8c092567f
children 164e49fc12a7
files lisp/url/url-http.el
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/url/url-http.el	Wed Nov 15 16:34:20 2006 +0000
+++ b/lisp/url/url-http.el	Wed Nov 15 23:07:11 2006 +0000
@@ -933,7 +933,8 @@
 	    (old-http nil)
 	    (content-length nil))
 	(goto-char (point-min))
-	(if (not (looking-at "^HTTP/[1-9]\\.[0-9]"))
+	(if (and (looking-at ".*\n")	; have one line at least
+		 (not (looking-at "^HTTP/[1-9]\\.[0-9]")))
 	    ;; Not HTTP/x.y data, must be 0.9
 	    ;; God, I wish this could die.
 	    (setq end-of-headers t