Skip to content

Commit

Permalink
Save a little memory
Browse files Browse the repository at this point in the history
  • Loading branch information
nigelhorne committed Feb 23, 2024
1 parent 2d4d21e commit 5134ed9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions bin/create_db.PL
Original file line number Diff line number Diff line change
Expand Up @@ -483,10 +483,10 @@ sub flush($)
my $dbh = shift;

# Remove duplicates
my %seen;
my @deduped;
my %seen;

foreach my $item(@queue) {
while(my $item = pop @queue) {
# my $first = $item->{'first'};
# if(!defined($first)) {
# $item->{'first'} = '';
Expand Down Expand Up @@ -518,7 +518,8 @@ sub flush($)
# print "$k\n";
}
}
@queue = (); # Make sure Perl really frees all memory
undef @queue; # Make sure Perl really frees all memory
undef %seen;

my $query;

Expand Down

0 comments on commit 5134ed9

Please sign in to comment.