From: Peter Rabbitson Date: Mon, 2 Nov 2015 22:50:17 +0000 (+0100) Subject: Fix bizarre segfault on older perls, not seen on CI ( augments d63c9e64 ) X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=5f74ed3a5e1eea6afa1d28894957dcfae44c79fb;p=dbsrgits%2FDBIx-Class-Historic.git Fix bizarre segfault on older perls, not seen on CI ( augments d63c9e64 ) --- diff --git a/lib/DBIx/Class.pm b/lib/DBIx/Class.pm index 863cb19..33e84ce 100644 --- a/lib/DBIx/Class.pm +++ b/lib/DBIx/Class.pm @@ -32,7 +32,12 @@ __PACKAGE__->_skip_namespace_frames('^DBIx::Class|^SQL::Abstract|^Try::Tiny|^Cla # However it is the right thing to do in order to get # various install bases to highlight their brokenness # Remove at some unknown point in the future -sub DESTROY { &DBIx::Class::_Util::detected_reinvoked_destructor } +# +# The oddball BEGIN is there for... reason unknown +# It does make non-segfaulty difference on pre-5.8.5 perls, so shrug +BEGIN { + sub DESTROY { &DBIx::Class::_Util::detected_reinvoked_destructor }; +} sub mk_classdata { shift->mk_classaccessor(@_);