X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXUtil.pm;h=018a404a6249baa43fe2987ff24520c25cf33d59;hb=980b697bd47c8f575b1c9a7f01f9b01adc6746bd;hp=2c814ea33d834cbe5001eede20eecc0755059695;hpb=2177bb0e95a5ec8797f5a0d47bd2070666a92653;p=spider.git diff --git a/perl/DXUtil.pm b/perl/DXUtil.pm index 2c814ea3..018a404a 100644 --- a/perl/DXUtil.pm +++ b/perl/DXUtil.pm @@ -333,7 +333,7 @@ sub unpad # check that a field only has callsign characters in it sub is_callsign { - return $_[0] =~ /^(?:[A-Z]{1,2}\d+|\d[A-Z]\d+)[A-Z]+(?:-\d{1,2}|\/[A-Z0-9]+)?$/; + return $_[0] =~ /^(?:[A-Z]{1,2}\d+|\d[A-Z]\d+)[A-Z]{1,3}(?:-\d{1,2}|\/(?:[A-Z]{1,2}\d{0,2}|\d[A-Z]\d{0,2}))?$/; } # check that a PC protocol field is valid text @@ -351,7 +351,7 @@ sub is_pcflag # check that a thing is a frequency sub is_freq { - return $_[0] =~ /^[\d\.]+$/; + return $_[0] =~ /^\d+(?:\.\d+)?$/; } # check that a thing is just digits