/[clipping]/mimex
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /mimex

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by dpavlin, Sat Nov 3 10:15:41 2001 UTC revision 1.5 by dpavlin, Sat Nov 3 11:02:30 2001 UTC
# Line 27  sub dump_entity { Line 27  sub dump_entity {
27      my $ent = shift;      my $ent = shift;
28      my @parts = $ent->parts;      my @parts = $ent->parts;
29    
30        my $md5=md5_hex(time());
31        mkdir "$outdir/$md5",0755 || die "mkdir $outdir/$md5: $!";
32    
33      if (@parts) {       # multipart...      if (@parts) {       # multipart...
34          map { dump_entity($_) } @parts;          map { dump_entity($_) } @parts;
35      } else {            # single part...      } else {            # single part...
# Line 43  sub dump_entity { Line 46  sub dump_entity {
46                  $new=~s/ +/_/g;                  $new=~s/ +/_/g;
47                  $new=~s/^.*\/([^\/]+)$/$1/g;                  $new=~s/^.*\/([^\/]+)$/$1/g;
48                  $new=~s/[^a-zA-Z._0-9]//g;                  $new=~s/[^a-zA-Z._0-9]//g;
                 my $md5=md5_hex($new.time());  
                 mkdir "$outdir/$md5",0755 || die "mkdir $outdir/$md5: $!";  
49                  rename $file,"$outdir/$md5/$new" || die "$file -> $md5 $new: $!";                  rename $file,"$outdir/$md5/$new" || die "$file -> $md5 $new: $!";
50                  print MAIL "\n","-" x 76,"\nhttp://store.pliva.hr/$md5/$new\n";                  print MAIL "\n","-" x 76,"\nhttp://store.pliva.hr/$md5/$new\n";
51                  print LOG "http://store.pliva.hr/$md5/$new\n";                  print LOG "$md5/$new\n";
52          }          }
53      }      }
54  }  }

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

  ViewVC Help
Powered by ViewVC 1.1.26