commit 7d806ebbb66276a8f07304a6280c379e9fdbb10b
Author: Juergen Spitzmueller <[email protected]>
Date:   Sun Mar 10 13:23:36 2019 +0100

    Do not percent-encode & in urls
    
    This is query syntax
    
    Fixes: #11511
    
    follows up [c2db448ff5/lyxgit]
    
    (cherry picked from commit 936cddc715d3a49ffbde42bba0cb19120701bc57)
---
 src/insets/InsetHyperlink.cpp |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/insets/InsetHyperlink.cpp b/src/insets/InsetHyperlink.cpp
index 93dbaa9..07185a4 100644
--- a/src/insets/InsetHyperlink.cpp
+++ b/src/insets/InsetHyperlink.cpp
@@ -133,8 +133,8 @@ void InsetHyperlink::latex(otexstream & os,
        if (!url.empty()) {
                // Use URI/URL-style percent-encoded string (hexadecimal).
                // We exclude some characters that must not be transformed
-               // in hrefs (% # / : ? =) or that we need to treat manually (\).
-               url = to_percent_encoding(url, from_ascii("%#\\/:?="));
+               // in hrefs (% # / : ? = &) or that we need to treat manually 
(\).
+               url = to_percent_encoding(url, from_ascii("%#\\/:?=&"));
                // We handle \ manually since \\ is valid
                for (size_t i = 0, pos;
                        (pos = url.find('\\', i)) != string::npos;

Reply via email to