From: Shun-ichi GOTO <gotoh@taiyo.co.jp>
Subject: First call of url-generic-parse-url<f> is broken
Date: Mon, 13 Nov 2006 15:21:47 +0900 [thread overview]
Message-ID: <uk61z6f44.wl%gotoh@taiyo.co.jp> (raw)
The function url-generic-parse-url<f> returns strange data on the first call.
Here is actual example:
;; this is my local setting
(setq url-proxy-services
'(("http" . "zippo:8080"))
;; first try
(url-generic-parse-url "http://www.meadowy.org/~gotoh/projects/trac-wiki/xmlrpc\
")
=> ["http" nil nil "www.meadowy.org" 80 "http://zippo:8080/" nil nil t]
~~~~~~~~~~~~~~~~~~~
strange!
;; again
(url-generic-parse-url "http://www.meadowy.org/~gotoh/projects/trac-wiki/xmlrpc\
")
=> ["http" nil nil "www.meadowy.org" 80 "/~gotoh/projects/trac-wiki/xmlrpc" nil ni\
l t]
I chaised and found a bug.
url-generic-parse-url<f> calls url-scheme-get-property<f> in the
middle of the parsing to get port number for scheme.
But url-scheme-get-property<f> invoke url-generic-parse-url<f> again
to parse url value in url-proxy-services.
Because url-generic-parse-url<f> uses fixed named buffer,
the buffer contents for first parse is broken by 2nd one.
I suggest using with-temp-buffer<f> for allocating working buffer
instead of get-buffer-create<f>.
Or move use of url-schem-get-property to end of function
before (vector ...).
--- Regards,
Shun-ichi Goto <gotoh@taiyo.co.jp>
R&D Group, TAIYO Corp., Tokyo, JAPAN
next reply other threads:[~2006-11-13 6:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-13 6:21 Shun-ichi GOTO [this message]
2006-11-15 23:15 ` First call of url-generic-parse-url<f> is broken Magnus Henoch
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=uk61z6f44.wl%gotoh@taiyo.co.jp \
--to=gotoh@taiyo.co.jp \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).