[Patch?] minor issue with highlighting URLs in plain text emal

Albrecht Dreß <[email protected]>
Newsgroups gmane.comp.gnome.apps.balsa
Message-ID <[email protected]>
Hi Jack:

Can you try the attached trivial patch?  It simply forces the URI regexp /not/ to end in a “.” character.  Please note that this is /wrong/ according to RFC 3986 which allows URI's to end with a dot, but should fix the issue for the vast majority of cases in the wild (the correct approach is to enclose the URI in <…> as below).  I guess it will also break multiline uri's where the first line ends with a dot, but that seems to be a /very/ exceptional case.

Am 03.07.18 20:21 schrieb(en) Jack via balsa-list:
> As I said - there was no markup at all in the HTML (i.e., no <a ...> entity) so I'm not surprised by the lack of link there.

Yes.  Correct behaviour of the widget!

> If I wasn't in a rush when I did click the link, I should easily have noticed the extra trailing dot, but I had other reasons to suspect the sender of a bit of technical illiteracy.  When I did contact them, I don't think the lack of any plain text version registered in her brain, but the inclusion of an image of a flyer (image, not pdf) with no accompanying text, did get her attention in terms of accessibility.  (US Congressman's office, so I would hope they care about that.)

“Technical illiteracy” is probably a proper description… ;-)  And keep in mind those people decide on the more or less complex voting machines you use.  There has been an impressive talk about this topic by Alex Halderman at the DIMVA conference last week (<http://www.dimva2018.org/keynotes/#Keynote-2>; slides not online, but Google/DuckDuckGo/Startpage may find some references)…

Cheers, Albrecht.

_______________________________________________
balsa-list mailing list
[email protected]
https://mail.gnome.org/mailman/listinfo/balsa-list
fix-uri-tailing-dot.diff (text/x-patch, 525 B)
diff --git a/libbalsa/mime.c b/libbalsa/mime.c
index b4a7fe014..1ebd85bd0 100644
--- a/libbalsa/mime.c
+++ b/libbalsa/mime.c
@@ -857,7 +857,8 @@ get_url_reg(void)
     static struct url_regex_info info = {
         NULL,
         "(((https?|ftps?|nntp)://)|(mailto:|news:))"
-            "(%[0-9A-F]{2}|[-_.!~*';/?:@&=+$,#[:alnum:]])+",
+            "(%[0-9A-F]{2}|[-_.!~*';/?:@&=+$,#[:alnum:]])+"
+            "(%[0-9A-F]{2}|[-_!~*';/?:@&=+$,#[:alnum:]])",
         __func__,
         "url regex compilation failed"
     };
signature.asc (application/pgp-signature, 488 B)
-----BEGIN PGP SIGNATURE-----

iQEzBAABCAAdFiEEcCEPemLFTtyGf4zATKlvDmfn2fgFAls7zA0ACgkQTKlvDmfn
2fjhJwf+MuvhJUrBoWbPzzV5e9POvh0f7eDmfkUDlh/W4W3a1uueLotoJs0eAoxe
tGTVl+w2XyimyikXe/PlgobjPQ6BgHcUqNI1HZBpijadoxUfdhtGM0a18Zeqg1XN
8uzPONRBwImb+go9vGK9YU7bM9Cca2VVCZ2VpR7WQvINfoDapGK/u/t64877YG5b
pn0k6D+0j3aaEZb0bdsIbuh/wLUO+zLiBqNXR6UZvZOZdyIJR9uJCVIYOBlokKSW
7oN8MqTl7IBPHJvayoqOMkA5M+kitw1AdKoVkGRDKt9Mgrlr1v7rXrZQZi9jEo3w
oZ73473Gp1gskQ01MeZPJ+icHPJYyw==
=Q7eq
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.