diff options
author | Raphaël Hertzog <hertzog@debian.org> | 2010-01-22 01:46:40 +0100 |
---|---|---|
committer | Raphaël Hertzog <hertzog@debian.org> | 2010-01-22 01:57:39 +0100 |
commit | efd281e8723f9e80e65cbdcefb304483c35ad963 (patch) | |
tree | 1728db46c84f4b87446afd867e621df9496c2908 /scripts/Dpkg/Compression/Compressor.pm | |
parent | c5fea0a576586e993ad8af3c6b2d0897297cd9f7 (diff) | |
download | dpkg-efd281e8723f9e80e65cbdcefb304483c35ad963.tar.gz |
Dpkg::Compression: new API based on public functions
This API change requires lots of adjustements through the source code.
Diffstat (limited to 'scripts/Dpkg/Compression/Compressor.pm')
-rw-r--r-- | scripts/Dpkg/Compression/Compressor.pm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/Dpkg/Compression/Compressor.pm b/scripts/Dpkg/Compression/Compressor.pm index 4ca4ff454..4da35a129 100644 --- a/scripts/Dpkg/Compression/Compressor.pm +++ b/scripts/Dpkg/Compression/Compressor.pm @@ -32,7 +32,7 @@ our $default_compression_level = 9; sub set_default_compression { my ($self, $method) = @_; error(_g("%s is not a supported compression"), $method) - unless $comp_supported{$method}; + unless compression_is_supported($method); $default_compression = $method; } @@ -58,7 +58,7 @@ sub new { sub set_compression { my ($self, $method) = @_; error(_g("%s is not a supported compression method"), $method) - unless $comp_supported{$method}; + unless compression_is_supported($method); $self->{"compression"} = $method; } @@ -71,7 +71,7 @@ sub set_compression_level { sub get_compress_cmdline { my ($self) = @_; - my @prog = ($comp_prog{$self->{"compression"}}); + my @prog = (compression_get_property($self->{"compression"}, "comp_prog")); my $level = "-" . $self->{"compression_level"}; $level = "--" . $self->{"compression_level"} if $self->{"compression_level"} =~ m/best|fast/; @@ -81,7 +81,7 @@ sub get_compress_cmdline { sub get_uncompress_cmdline { my ($self) = @_; - return ($comp_decomp_prog{$self->{"compression"}}); + return (compression_get_property($self->{"compression"}, "decomp_prog")); } sub _sanity_check { |