Revised the compression switches when calling binary executables for consistency.

This commit is contained in:
依瑪貓 2022-03-19 10:15:04 +08:00
parent 37de9cf319
commit aaa5b34074

16
arclog
View File

@ -2285,7 +2285,7 @@ sub open_write : method {
($self->{"file"}, $self->{"FH"}) = ($file, $FH); ($self->{"file"}, $self->{"FH"}) = ($file, $FH);
$EXEC = where_is "bzip2" if !defined $EXEC; $EXEC = where_is "bzip2" if !defined $EXEC;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2356,7 +2356,7 @@ sub open_append : method {
open STDIN, "<&", $STDIN or die "$THIS_FILE: STDIN: $!"; open STDIN, "<&", $STDIN or die "$THIS_FILE: STDIN: $!";
print STDERR "done\n" if $VERBOSE > 2; print STDERR "done\n" if $VERBOSE > 2;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2384,7 +2384,7 @@ sub open_append : method {
# A whole new file # A whole new file
} else { } else {
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2444,7 +2444,7 @@ sub close : method {
# Create empty compressed content # Create empty compressed content
print STDERR " Applying empty compressed content ... " if $VERBOSE > 2; print STDERR " Applying empty compressed content ... " if $VERBOSE > 2;
$EXEC = where_is "bzip2" if !defined $EXEC; $EXEC = where_is "bzip2" if !defined $EXEC;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
# Redirect STDOUT to $FH # Redirect STDOUT to $FH
@ -2743,7 +2743,7 @@ sub open_write : method {
($self->{"file"}, $self->{"FH"}) = ($file, $FH); ($self->{"file"}, $self->{"FH"}) = ($file, $FH);
$EXEC = where_is "xz" if !defined $EXEC; $EXEC = where_is "xz" if !defined $EXEC;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2814,7 +2814,7 @@ sub open_append : method {
open STDIN, "<&", $STDIN or die "$THIS_FILE: STDIN: $!"; open STDIN, "<&", $STDIN or die "$THIS_FILE: STDIN: $!";
print STDERR "done\n" if $VERBOSE > 2; print STDERR "done\n" if $VERBOSE > 2;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2842,7 +2842,7 @@ sub open_append : method {
# A whole new file # A whole new file
} else { } else {
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
print STDERR " Starting $CMD to file ... " if $VERBOSE > 2; print STDERR " Starting $CMD to file ... " if $VERBOSE > 2;
@ -2902,7 +2902,7 @@ sub close : method {
# Create empty compressed content # Create empty compressed content
print STDERR " Applying empty compressed content ... " if $VERBOSE > 2; print STDERR " Applying empty compressed content ... " if $VERBOSE > 2;
$EXEC = where_is "xz" if !defined $EXEC; $EXEC = where_is "xz" if !defined $EXEC;
@_ = ($EXEC, "-9f"); @_ = ($EXEC, "-c9f");
@_ = map "\"$_\"", @_ if $^O eq "MSWin32"; @_ = map "\"$_\"", @_ if $^O eq "MSWin32";
$CMD = join " ", @_; $CMD = join " ", @_;
# Redirect STDOUT to $FH # Redirect STDOUT to $FH