/[webpac]/trunk/all2xml.pl
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 /trunk/all2xml.pl

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

revision 320 by dpavlin, Sun Apr 18 00:57:39 2004 UTC revision 379 by dpavlin, Wed Jul 7 09:55:45 2004 UTC
# Line 168  sub data2xml { Line 168  sub data2xml {
168                          ($s,$se,$d,$i) = (0,1,0,0);                          ($s,$se,$d,$i) = (0,1,0,0);
169                  } elsif (lc($type) =~ /^lookup/) {                  } elsif (lc($type) =~ /^lookup/) {
170                          ($s,$se,$d,$i,$il) = (0,1,0,0,1);                          ($s,$se,$d,$i,$il) = (0,1,0,0,1);
171                    } elsif ($type) {
172                            print STDERR "WARNING: unknown type: $type\n";
173                  }                  }
174                  return ($s,$se,$d,$i,$il);                  return ($s,$se,$d,$i,$il);
175          }          }
# Line 637  foreach my $database ($cfg->Sections) { Line 639  foreach my $database ($cfg->Sections) {
639          my $lookup_file = $cfg -> val($database, 'lookup_newfile'); # optional          my $lookup_file = $cfg -> val($database, 'lookup_newfile'); # optional
640          if ($lookup_file) {          if ($lookup_file) {
641                  #tie %lhash, 'GDBM_File', $lookup_file, &GDBM_NEWDB, 0644;                  #tie %lhash, 'GDBM_File', $lookup_file, &GDBM_NEWDB, 0644;
642                    if (! -e $lookup_file) {
643                            open(LOOKUP, "> $lookup_file") || die "can't create $lookup_file': $!";
644                            close(LOOKUP);
645                    }
646                  tie %lhash, 'TDB_File', $lookup_file, TDB_CLEAR_IF_FIRST, O_RDWR, 0644;                  tie %lhash, 'TDB_File', $lookup_file, TDB_CLEAR_IF_FIRST, O_RDWR, 0644;
647                  print STDERR "creating lookup file '$lookup_file'\n";                  print STDERR "creating lookup file '$lookup_file'\n";
648                  # delete memory cache for lookup file                  # delete memory cache for lookup file

Legend:
Removed from v.320  
changed lines
  Added in v.379

  ViewVC Help
Powered by ViewVC 1.1.26