[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r107839: (url-retrieve-internal): Hex
From: |
Lars Magne Ingebrigtsen |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r107839: (url-retrieve-internal): Hexify multibye URL string first when necessary. |
Date: |
Tue, 10 Apr 2012 13:22:08 +0200 |
User-agent: |
Bazaar (2.3.1) |
------------------------------------------------------------
revno: 107839
fixes bug(s): http://debbugs.gnu.org/7017
author: William Xu <address@hidden>
committer: Lars Magne Ingebrigtsen <address@hidden>
branch nick: trunk
timestamp: Tue 2012-04-10 13:22:08 +0200
message:
(url-retrieve-internal): Hexify multibye URL string first when necessary.
Also mention this in the relevant doc strings.
modified:
lisp/url/ChangeLog
lisp/url/url.el
=== modified file 'lisp/url/ChangeLog'
--- a/lisp/url/ChangeLog 2012-04-10 02:14:13 +0000
+++ b/lisp/url/ChangeLog 2012-04-10 11:22:08 +0000
@@ -1,3 +1,13 @@
+2012-04-10 William Xu <address@hidden> (tiny change)
+
+ * url.el (url-retrieve-internal): Hexify multibye URL string first
+ when necessary (bug#7017).
+
+2012-04-10 Lars Magne Ingebrigtsen <address@hidden>
+
+ * url.el (url-retrieve-internal): Mention utf-8 encoding.
+ (url-retrieve): Ditto.
+
2012-04-10 Lars Magne Ingebrigtsen <address@hidden>
* url-util.el (url-unhex-string): Add an optional CODING-SYSTEM
=== modified file 'lisp/url/url.el'
--- a/lisp/url/url.el 2012-02-20 08:22:41 +0000
+++ b/lisp/url/url.el 2012-04-10 11:22:08 +0000
@@ -149,7 +149,9 @@
If SILENT, then don't message progress reports and the like.
If INHIBIT-COOKIES, cookies will neither be stored nor sent to
-the server."
+the server.
+If URL is a multibyte string, it will be encoded as utf-8 and
+URL-encoded before it's used."
;;; XXX: There is code in Emacs that does dynamic binding
;;; of the following variables around url-retrieve:
;;; url-standalone-mode, url-gateway-unplugged, w3-honor-stylesheets,
@@ -171,11 +173,16 @@
If SILENT, don't message progress reports and the like.
If INHIBIT-COOKIES, cookies will neither be stored nor sent to
-the server."
+the server.
+If URL is a multibyte string, it will be encoded as utf-8 and
+URL-encoded before it's used."
(url-do-setup)
(url-gc-dead-buffers)
(if (stringp url)
(set-text-properties 0 (length url) nil url))
+ (when (multibyte-string-p url)
+ (let ((url-unreserved-chars (append '(?: ?/) url-unreserved-chars)))
+ (setq url (url-hexify-string url))))
(if (not (vectorp url))
(setq url (url-generic-parse-url url)))
(if (not (functionp callback))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r107839: (url-retrieve-internal): Hexify multibye URL string first when necessary.,
Lars Magne Ingebrigtsen <=