diff --git a/ChangeLog b/ChangeLog
index fdea52655..7d3255907 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2015-12-11 Peter Stephenson
+
+ * Functions/Zle/url-quote-magic: match, mbegin, mend should be
+ locally.
+
2015-12-11 Oliver Kiddle
* 37383: Matthew Martin: Completion/Unix/Command/_elfdump,
diff --git a/Functions/Zle/url-quote-magic b/Functions/Zle/url-quote-magic
index 0e49573db..7ee281ea4 100644
--- a/Functions/Zle/url-quote-magic
+++ b/Functions/Zle/url-quote-magic
@@ -115,7 +115,7 @@ alias globurl='noglob urlglobber '
function url-quote-magic {
setopt localoptions noksharrays extendedglob
local qkey="${(q)KEYS}"
- local -a reply
+ local -a reply match mbegin mend
if [[ "$KEYS" != "$qkey" ]]
then
local lbuf="$LBUFFER$qkey"