From: Marius Gavrilescu Date: Sat, 14 Feb 2015 22:25:01 +0000 (+0200) Subject: Force using Archive::Tar when unpacking compressed tarballs on solaris X-Git-Tag: 0.001001~2 X-Git-Url: http://git.ieval.ro/?p=zeal.git;a=commitdiff_plain;h=ddea233ddf3095cfa6892de0ffeabb4037d6d766 Force using Archive::Tar when unpacking compressed tarballs on solaris --- diff --git a/lib/Zeal/Feed.pm b/lib/Zeal/Feed.pm index b4bbc52..ba1767f 100644 --- a/lib/Zeal/Feed.pm +++ b/lib/Zeal/Feed.pm @@ -62,6 +62,11 @@ sub _unpack_tar_to_dir { my $oldwd = getcwd; chdir $dir; my $tar = which 'tar' or which 'gtar'; + + # uncoverable branch true + # uncoverable condition false + local $ENV{ZEAL_USE_INTERNAL_TAR} = 1 if $file =~ /gz$|bz2$/ && $^O eq 'solaris'; + if ($tar && !$ENV{ZEAL_USE_INTERNAL_TAR}) { my $arg = '-xf'; $arg = '-xzf' if $file =~ /[.]t?gz$/;