From 8eb2c4f7c0aed11810280c6dfa63f75fd961e3cd Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 2 Feb 2019 07:35:06 +0000 Subject: hlmod: make into a singleton It turns out there's no point in having multiple instances of this or having to worry about destruction or destruction ordering. This will make it easier to reuse the one instance we have across different modules. --- lib/PublicInbox/ViewVCS.pm | 5 ----- 1 file changed, 5 deletions(-) (limited to 'lib/PublicInbox/ViewVCS.pm') diff --git a/lib/PublicInbox/ViewVCS.pm b/lib/PublicInbox/ViewVCS.pm index acdd822d..0fb6b64e 100644 --- a/lib/PublicInbox/ViewVCS.pm +++ b/lib/PublicInbox/ViewVCS.pm @@ -25,11 +25,6 @@ my $hl = eval { PublicInbox::HlMod->new; }; -# we need to trigger highlight::CodeGenerator::deleteInstance -# in HlMod::DESTROY before the rest of Perl shuts down to avoid -# a segfault at shutdown -END { $hl = undef }; - my %QP_MAP = ( A => 'oid_a', B => 'oid_b', a => 'path_a', b => 'path_b' ); my $max_size = 1024 * 1024; # TODO: configurable my $BIN_DETECT = 8000; # same as git -- cgit v1.2.3-24-ge0c7