Queue buffered log entries when destroyed.

This commit is contained in:
Daniel Nichter
2013-06-09 17:33:01 -07:00
parent 0b16c02468
commit aadb5dbd80
2 changed files with 8 additions and 0 deletions

View File

@@ -282,6 +282,10 @@ sub stop_online_logging {
sub DESTROY {
my $self = shift;
foreach my $log_entry ( shift @{$self->_buffer} ) {
last unless defined $log_entry;
$self->_queue_log_entry(@$log_entry);
}
$self->stop_online_logging();
return;
}