--- Convert-UUlib/example-decoder 2002/04/05 21:56:57 1.5 +++ Convert-UUlib/example-decoder 2002/08/19 23:25:34 1.6 @@ -20,6 +20,7 @@ SetOption (OPT_IGNMODE, 1); SetOption (OPT_VERBOSE, 1); +#SetOption (OPT_DOTDOT, 1); # show the three ways you can set callback functions SetFNameFilter (\&namefilter); @@ -45,6 +46,8 @@ # - filename.par (04/55) return $1 if /- "?(\S+\.\S+?)"? (:yenc )?\(\d+\/\d+\)/i; + return $1 if /No\.[ 0-9]+ (\S+\....) (?:\d+ bytes )?\[/; + # otherwise just pass what we have return (); }; @@ -79,12 +82,16 @@ print "\n"; } - print strerror($uu->decode_temp)."\n"; - print " temporarily decoded to ",$uu->binfile,"\n"; - $uu->remove_temp; - - print strerror($uu->decode)."\n"; - print " saved as uudst/",$uu->filename,"\n"; + if ($uu->state & FILE_OK) { + print strerror($uu->decode_temp)."\n"; + print " temporarily decoded to ",$uu->binfile,"\n"; + $uu->remove_temp; + + print strerror($uu->decode)."\n"; + print " saved as uudst/",$uu->filename,"\n"; + } else { + print "file NOT ok, not decoding\n"; + } } print "cleanup...\n";