Re: lynx gopher telnet item fix

Thomas Dickey <[email protected]>
Newsgroups gmane.comp.web.lynx.devel
Message-ID <[email protected]>
On Mon, Jan 06, 2025 at 05:51:51PM -0800, Ben Collver wrote:
> Good day,
> 
> The current version of lynx cannot open the telnet link in the following
> gopher menu.
> 
> gopher://mud.nemesis.de/1
> 
> When the selector is empty, lynx uses a format with the wrong number
> of arguments.
> 
> >From lynx2.9.2/WWW/Library/Implementation/HTGopher.c:
> 
>     const char *format = *selector ? "%s//%s@%s/" : "%s//%s/";
>     ...
>     HTSprintf0(&address, format, STR_TELNET_URL, selector, host);
> 
> The problem happens when the format calls for 2 arguments, but lynx
> passes it 3.  Consequently, it ignores the host in the 3rd argument
> and this results in a broken telnet item.
> 
> Attached is a patch to fix this problem.

thanks :-)

-- 
Thomas E. Dickey <[email protected]>
https://invisible-island.net
signature.asc (application/pgp-signature, 659 B)
-----BEGIN PGP SIGNATURE-----

iQGzBAABCgAdFiEEGYgtkt2kxADCLA1WzCr0RyFnvgMFAmd87RQACgkQzCr0RyFn
vgP5AAwA2jBhmS1nh39MBrp5+1C5+e1SNq5Vn6YCvAzyLyAC/7OaHfzs+KziL8eR
Jy65KelJnY1f31ujC2gGv7FTNOAXERm+kPb+69Q9lEa20k5kfELayzXUdoI4ProM
51YsCmSaprKtAS4dxn1/7sXgl0CXsaD9n9mD/cyjzky93wgXB+Gv4iEkIxp2pQYG
OlArJPrKTtVKuHAvtonxnOC493N4nx3vbLK5KtxrI0r0EpFDB+M+D+znaZlcfFFQ
DGi5Y7yVlWoRWm1/TjjbLlffNpiQ/5mpeFaW/WMpV/qhgnPGOk/ZsHxZgSxUPd71
kBLjMrv19HJeOc2wKYuW9JtZ4XySXZu5MRBWMy4JZqtzbQ1CfJ6OA2AQfpgG6aSc
WFhXXpdpikWbzK62sfKMoYhZNjLXk10cQN/1Ty/2Kr82vlPk8Zxk+tL6aKtga/Gj
j/vf9GVvY/MBHVG+Oww4ba6DSsV7AQIfX19dClQXtbj1fEBhrlAjrm2j+yV8ksEq
38AXZN71
=IDkW
-----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.