diff options
author | Daniel Friesel <derf@finalrewind.org> | 2021-02-06 18:05:51 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2021-02-06 18:05:51 +0100 |
commit | b8b70bca030ff0db174bfde92418ed98617b0bdb (patch) | |
tree | ee3557168bdfdbbb0fb4102f0a081cf9dc29218e /lib/DBInfoscreen | |
parent | d446b73edd84565948702e3418f17a8c5e04aa9e (diff) |
HAFAS: Remove all illegal linebreaks from attributes, not just the first3.10.7
Diffstat (limited to 'lib/DBInfoscreen')
-rw-r--r-- | lib/DBInfoscreen/Helper/HAFAS.pm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/DBInfoscreen/Helper/HAFAS.pm b/lib/DBInfoscreen/Helper/HAFAS.pm index a7c07c3..b97248d 100644 --- a/lib/DBInfoscreen/Helper/HAFAS.pm +++ b/lib/DBInfoscreen/Helper/HAFAS.pm @@ -121,8 +121,11 @@ sub get_xml_p { =~ s{<Attribute([^>]+)text="([^"]*)"([^"=]*)""}{<Attribute$1text="$2*$3*"}s; # Dito for <HIMMessage [...] lead="[...]<br>[...]">. - $body - =~ s{<HIMMessage([^>]+)lead="([^"]*)<br/?>([^"=]*)"}{<HIMMessage$1lead="$2 $3"}s; + while ( $body + =~ s{<HIMMessage([^>]+)lead="([^"]*)<br/?>([^"=]*)"}{<HIMMessage$1lead="$2 $3"}gs + ) + { + } my $tree; |