From cc3f3c236235378698bbb66b093fac72e9784f38 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 May 2017 17:51:44 +0200 Subject: Adding upstream version 1.19. Signed-off-by: Daniel Baumann --- fast_encoder.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'fast_encoder.h') diff --git a/fast_encoder.h b/fast_encoder.h index 2e0bd50..37ab8ef 100644 --- a/fast_encoder.h +++ b/fast_encoder.h @@ -1,5 +1,5 @@ /* Lzip - LZMA lossless data compressor - Copyright (C) 2008-2016 Antonio Diaz Diaz. + Copyright (C) 2008-2017 Antonio Diaz Diaz. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -17,7 +17,7 @@ class FLZ_encoder : public LZ_encoder_base { - int key4; // key made from latest 4 bytes + unsigned key4; // key made from latest 4 bytes void reset_key4() { @@ -35,9 +35,8 @@ class FLZ_encoder : public LZ_encoder_base if( available_bytes() >= 4 ) { key4 = ( ( key4 << 4 ) ^ buffer[pos+3] ) & key4_mask; - const int newpos = prev_positions[key4]; + pos_array[cyclic_pos] = prev_positions[key4]; prev_positions[key4] = pos + 1; - pos_array[cyclic_pos] = newpos; } move_pos(); } -- cgit v1.2.3