misc/contrib/perl4/a2dbm
raw| 1 | #!/usr/bin/perl |
| 2 | |
| 3 | # this is broken, only works whith perl4 |
| 4 | |
| 5 | dbmopen(ifdbm,"ifdbm",0666); |
| 6 | |
| 7 | open(alias,"/usr/lib/ifmail/Alias") || die "Cannot open alias file"; |
| 8 | while(<alias>) { |
| 9 | unless (/^#/) { |
| 10 | /([^ ]*) *(.*) *$/; |
| 11 | print $1, "--", $2, "\n"; |
| 12 | $ifdbm{$2} = $1; |
| 13 | } |
| 14 | } |
| 15 | |
| 16 | dbmclose(ifdbm); |