Subject: bug#71972: 31.0.50; Tramp does not parse ipv6 address with port correctly

From: Michael Albinus <[email-masked]>
Date: Sat, 06 Jul 2024 17:02:28 +0200

Yikai Zhao <[email-masked]> writes:

Hi,

> To reproduce:
>
>   (tramp-dissect-file-name "/ssh:[2001::abcd]#2202:/tmp/xxx")
>
> Expected result: the result "port" should be "2202"
>
> Current result: the result "port" is empty

Indeed.

--8<---------------cut here---------------start------------->8---
(tramp-dissect-file-name "/ssh:[2001::abcd]#2202:/tmp/xxx")
=> (tramp-file-name "ssh" nil nil "2001::abcd#2202" nil "/tmp/xxx" nil)
--8<---------------cut here---------------end--------------->8---

That is a structure, which has "2001::abcd#2202" as host name. Ouch.

Will see how I could fix it.

Best regards, Michael.