Fossil SCM

When creating a hyperlink via line selection and the mouse in the /file view, do not decode the inbound URL, to avoid mis-handling of filenames which contain + signs. This resolves [forum:6f276193d2cfa5ab|forum post 6f276193d2cfa5ab].

stephan 2025-06-04 08:15 trunk
Commit 7641c8296144dd9000c5a571d290d07a7e0508c947564639af666987897f4e92
--- src/fossil.numbered-lines.js
+++ src/fossil.numbered-lines.js
@@ -21,14 +21,11 @@
2121
const tdLn = tbl.querySelector('td.line-numbers');
2222
const urlArgsRaw = (window.location.search||'?')
2323
.replace(/&?\budc=[^&]*/,'') /* "update display prefs cookie" */
2424
.replace(/&?\bln=[^&]*/,'') /* inbound line number/range */
2525
.replace('?&','?');
26
- var urlArgsDecoded = urlArgsRaw;
27
- try{urlArgsDecoded = decodeURIComponent(urlArgsRaw);}
28
- catch{}
29
- const lineState = { urlArgs: urlArgsDecoded, start: 0, end: 0 };
26
+ const lineState = { urlArgs: urlArgsRaw, start: 0, end: 0 };
3027
const lineTip = new F.PopupWidget({
3128
style: {
3229
cursor: 'pointer'
3330
},
3431
refresh: function(){
3532
--- src/fossil.numbered-lines.js
+++ src/fossil.numbered-lines.js
@@ -21,14 +21,11 @@
21 const tdLn = tbl.querySelector('td.line-numbers');
22 const urlArgsRaw = (window.location.search||'?')
23 .replace(/&?\budc=[^&]*/,'') /* "update display prefs cookie" */
24 .replace(/&?\bln=[^&]*/,'') /* inbound line number/range */
25 .replace('?&','?');
26 var urlArgsDecoded = urlArgsRaw;
27 try{urlArgsDecoded = decodeURIComponent(urlArgsRaw);}
28 catch{}
29 const lineState = { urlArgs: urlArgsDecoded, start: 0, end: 0 };
30 const lineTip = new F.PopupWidget({
31 style: {
32 cursor: 'pointer'
33 },
34 refresh: function(){
35
--- src/fossil.numbered-lines.js
+++ src/fossil.numbered-lines.js
@@ -21,14 +21,11 @@
21 const tdLn = tbl.querySelector('td.line-numbers');
22 const urlArgsRaw = (window.location.search||'?')
23 .replace(/&?\budc=[^&]*/,'') /* "update display prefs cookie" */
24 .replace(/&?\bln=[^&]*/,'') /* inbound line number/range */
25 .replace('?&','?');
26 const lineState = { urlArgs: urlArgsRaw, start: 0, end: 0 };
 
 
 
27 const lineTip = new F.PopupWidget({
28 style: {
29 cursor: 'pointer'
30 },
31 refresh: function(){
32

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button