RPM Community Forums

Mailing List Message of <rpm-devel>

Re: [CVS] RPM: rpm/ VENDOR rpm/rpmio/ macro.c

From: Anders F Björklund <afb@rpm5.org>
Date: Sun 13 Apr 2008 - 12:42:00 CEST
Message-Id: <D12A1479-7156-438E-981A-2A1DFCC64CC8@rpm5.org>
Ralf S. Engelschall wrote:

>   RPM Package Manager, CVS Repository
>   +    else if (   (file_len > 3 && strcasecmp(file+file_len-3,  
> ".lz") == 0)
>   +             || (file_len > 3 && strcasecmp(file+file_len-3, ". 
> 7z") == 0)
>   +             || (file_len > 5 && strcasecmp(file+file_len-5,  
> ".lzma") == 0)) {
>   +        *compressed = COMPRESSED_LZMA;
>   +        return 0;
>   +    }

This is not correct, 7-zip is a different format from LZMA (compare  
zip/gzip)
Might want to add a COMPRESSED_7ZIP some day, to handle the p7zip*  
archives...

* see http://sourceforge.net/projects/p7zip/

But it should probably be:

     else if (   (file_len > 4 && strcasecmp(file+file_len-3, ".tlz")  
== 0)
              || (file_len > 5 && strcasecmp(file+file_len-5,  
".lzma") == 0)) {

As far as I know, the suffix ".lz" isn't any more common than ".bz"  
suffix ?

--anders
Received on Sun Apr 13 12:42:02 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.