mirror of
https://github.com/upx/upx
synced 2025-09-28 19:06:07 +08:00
Filter parameters should be called "ft" instead of "fp".
committer: mfx <mfx> 1142301730 +0000
This commit is contained in:
parent
c43c484a62
commit
df04e8183d
|
@ -295,7 +295,7 @@ bool Packer::checkFinalCompressionRatio(const OutputFile *fo) const
|
|||
**************************************************************************/
|
||||
|
||||
void Packer::decompress(const upx_bytep in, upx_bytep out,
|
||||
bool verify_checksum, Filter *fp)
|
||||
bool verify_checksum, Filter *ft)
|
||||
{
|
||||
unsigned adler;
|
||||
|
||||
|
@ -316,8 +316,8 @@ void Packer::decompress(const upx_bytep in, upx_bytep out,
|
|||
// verify checksum of decompressed data
|
||||
if (verify_checksum)
|
||||
{
|
||||
if (fp) {
|
||||
fp->unfilter(out, ph.u_len);
|
||||
if (ft) {
|
||||
ft->unfilter(out, ph.u_len);
|
||||
}
|
||||
adler = upx_adler32(out, ph.u_len, ph.saved_u_adler);
|
||||
if (adler != ph.u_adler)
|
||||
|
@ -358,7 +358,7 @@ bool Packer::testOverlappingDecompression(const upx_bytep buf,
|
|||
}
|
||||
|
||||
|
||||
void Packer::verifyOverlappingDecompression(Filter *fp)
|
||||
void Packer::verifyOverlappingDecompression(Filter *ft)
|
||||
{
|
||||
assert(ph.c_len < ph.u_len);
|
||||
assert((int)ph.overlap_overhead > 0);
|
||||
|
@ -384,7 +384,7 @@ void Packer::verifyOverlappingDecompression(Filter *fp)
|
|||
if (offset + ph.c_len > obuf.getSize())
|
||||
return;
|
||||
memmove(obuf + offset, obuf, ph.c_len);
|
||||
decompress(obuf + offset, obuf, true, fp);
|
||||
decompress(obuf + offset, obuf, true, ft);
|
||||
obuf.checkState();
|
||||
#endif /* !UNUPX */
|
||||
}
|
||||
|
|
|
@ -161,7 +161,7 @@ protected:
|
|||
virtual bool compress(upx_bytep in, upx_bytep out,
|
||||
unsigned max_offset = 0, unsigned max_match = 0);
|
||||
virtual void decompress(const upx_bytep in, upx_bytep out,
|
||||
bool verify_checksum = true, Filter *fp = 0);
|
||||
bool verify_checksum = true, Filter *ft = NULL);
|
||||
virtual bool checkCompressionRatio(unsigned u_len, unsigned c_len) const;
|
||||
virtual bool checkFinalCompressionRatio(const OutputFile *fo) const;
|
||||
|
||||
|
@ -185,7 +185,7 @@ protected:
|
|||
unsigned range = 0,
|
||||
unsigned upper_limit = ~0u) const;
|
||||
// destructive decompress + verify
|
||||
virtual void verifyOverlappingDecompression(Filter *fp = 0);
|
||||
virtual void verifyOverlappingDecompression(Filter *ft = NULL);
|
||||
|
||||
|
||||
// packheader handling
|
||||
|
|
Loading…
Reference in New Issue
Block a user