7. improved the regex matching of badwords (more efficient, better coverage)
[spider.git] / perl / DXUtil.pm
index 018a404a6249baa43fe2987ff24520c25cf33d59..4246754832f4eb80fe99f7e5a77944e31b32844d 100644 (file)
@@ -10,6 +10,7 @@ package DXUtil;
 
 use Date::Parse;
 use IO::File;
+use File::Copy;
 use Data::Dumper;
 
 use strict;
@@ -26,6 +27,7 @@ require Exporter;
 @ISA = qw(Exporter);
 @EXPORT = qw(atime ztime cldate cldatetime slat slong yesno promptf 
                         parray parraypairs phex shellregex readfilestr writefilestr
+                        filecopy
              print_all_fields cltounix unpad is_callsign is_latlong
                         is_qra is_freq is_digits is_pctext is_pcflag insertitem deleteitem
             );
@@ -321,6 +323,11 @@ sub writefilestr
        }
 }
 
+sub filecopy
+{
+       copy(@_) or return $!;
+}
+
 # remove leading and trailing spaces from an input string
 sub unpad
 {