i tried both of these and realized neither worked

Index: infrastructure/bin/dpb
===================================================================
RCS file: /cvs/ports/infrastructure/bin/dpb,v
retrieving revision 1.93
diff -p -u -r1.93 dpb
--- infrastructure/bin/dpb      4 Jul 2013 17:45:34 -0000       1.93
+++ infrastructure/bin/dpb      11 Jul 2013 19:56:12 -0000
@@ -195,9 +195,14 @@ sub interpret_paths
                        $scale = $1;
                }
 
-               if (-f $file) {
-                       open my $fh, '<', $file or
+               my $fh;
+               if ($file eq '-') {
+                       $fh = *STDIN;
+               } elsif (-e $file && !-d $file) {
+                       open $fh, '<', $file or
                            $state->usage("Can't open $file");
+               }
+               if (defined $fh) {
                        my $_;
                        while (<$fh>) {
                                chomp;

Reply via email to