[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] ras: ignore '\r' of windows line endings.
From: |
Jose E. Marchesi |
Subject: |
Re: [PATCH] ras: ignore '\r' of windows line endings. |
Date: |
Thu, 15 Feb 2024 19:19:09 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Hi Hannes.
OK for both master and maint/poke-4.
Thanks!
> 2024-02-15 Hannes Domani <ssbssa@yahoo.de>
>
> * libpoke/ras: Ignore '\r' of windows line endings.
> ---
> libpoke/ras | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/libpoke/ras b/libpoke/ras
> index b474a095..f78d10f9 100755
> --- a/libpoke/ras
> +++ b/libpoke/ras
> @@ -552,6 +552,10 @@ BEGIN {
> args = gensub (/.*: *(".*") *:.*/, "\\1", "g", line)
> id = gensub (/ *([^ ]+) *:.*:.*/, "\\1", "g", line)
>
> + # Ignore '\r' of windows line endings.
> + if (substr (name, length (name), 1) == "\r")
> + name = substr (name, 1, length (name) - 1);
> +
> # Remove leading and trailing double-quotes wherever
> # appropriate
> name = substr (name, 2, length (name) - 2)