X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXProtout.pm;h=6ee4fbcc150272d2465a4d26f3e2e28ea2c68fdf;hb=9d573b0c36820badc1dc1e03bcd62960b572bb1c;hp=822beea5fe7bb3ce5ba0c0beaf81f5c206705f40;hpb=1910df7183401a62084e85c3ace179df492a6fbe;p=spider.git diff --git a/perl/DXProtout.pm b/perl/DXProtout.pm index 822beea5..6ee4fbcc 100644 --- a/perl/DXProtout.pm +++ b/perl/DXProtout.pm @@ -35,10 +35,9 @@ sub pc10 $user2 = ' '; $user1 = $to; } -# my $user2 = $via ? $to : ' '; -# my $user1 = $via ? $via : $to; $text = unpad($text); - $text = ' ' if !$text; + $text = ' ' unless $text && length $text > 0; + $text =~ s/\^/%5E/g; return "PC10^$from^$user1^$text^*^$user2^$main::mycall^~"; } @@ -49,6 +48,7 @@ sub pc11 my $hops = get_hops(11); my $t = time; $text = ' ' if !$text; + $text =~ s/\^/%5E/g; return sprintf "PC11^%.1f^$dxcall^%s^%s^$text^$mycall^$main::mycall^$hops^~", $freq, cldate($t), ztime($t); } @@ -61,6 +61,7 @@ sub pc12 $text = ' ' if !$text; $wx = '0' if !$wx; $tonode = '*' if !$tonode; + $text =~ s/\^/%5E/g; return "PC12^$call^$tonode^$text^$sysop^$main::mycall^$wx^$hops^~"; } @@ -101,8 +102,7 @@ sub pc17 # Request init string sub pc18 { - my $info = DXCluster::cluster; - return "PC18^$info^$DXProt::myprot_version^"; + return "PC18^DXSpider Version: $main::version Build: $main::build^$DXProt::myprot_version^"; } # @@ -193,8 +193,8 @@ sub pc28 sub pc29 { my ($fromnode, $tonode, $stream, $text) = @_; - $text =~ s/\^/:/og; # remove ^ -# $text =~ s/\~/S/og; + $text = ' ' unless $text && length $text > 0; + $text =~ s/\^/%5E/og; # remove ^ return "PC29^$fromnode^$tonode^$stream^$text^~"; }