X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FSpot.pm;h=5224f11f8bf261007e939299b27138c0a2017526;hb=efdf578cb0e69807c50a93427a34ab36a23f3823;hp=0df6891799dd8a3006da9c2a1c1880fcc16a86b6;hpb=c1a9cb4e04fb7db7898b05542e671c4e9e55fb93;p=spider.git diff --git a/perl/Spot.pm b/perl/Spot.pm index 0df68917..5224f11f 100644 --- a/perl/Spot.pm +++ b/perl/Spot.pm @@ -3,7 +3,7 @@ # # Copyright (c) - 1998 Dirk Koopman G1TLH # -# $Id$ +# # package Spot; @@ -21,11 +21,7 @@ use QSL; use strict; -use vars qw($VERSION $BRANCH); - -($VERSION, $BRANCH) = dxver(q$Revision$); - -use vars qw($fp $statp $maxspots $defaultspots $maxdays $dirprefix $duplth $dupage $filterdef $totalspots $hfspots $vhfspots $maxcalllth); +use vars qw($fp $statp $maxspots $defaultspots $maxdays $dirprefix $duplth $dupage $filterdef $totalspots $hfspots $vhfspots $maxcalllth $can_encode); $fp = undef; $statp = undef; @@ -406,6 +402,7 @@ sub dup } } my $otext = $text; + $text = Encode::encode("iso-8859-1", $text) if $main::can_encode && Encode::is_utf8($text, 1); $text =~ s/^\+\w+\s*//; # remove leading LoTW callsign $text = pack("C*", map {$_ & 127} unpack("C*", $text)); $text =~ s/\s{2,}[\dA-Z]?[A-Z]\d?$// if length $text > 24;