From 166ede1642869f46a0aae2df885772f7383e9ab2 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Tue, 23 Jan 2024 06:31:44 +0100 Subject: Adding upstream version 1.24. Signed-off-by: Daniel Baumann --- decoder.h | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'decoder.h') diff --git a/decoder.h b/decoder.h index 03adbbb..6efdfc2 100644 --- a/decoder.h +++ b/decoder.h @@ -1,5 +1,5 @@ /* Lziprecover - Data recovery tool for the lzip format - Copyright (C) 2009-2023 Antonio Diaz Diaz. + Copyright (C) 2009-2024 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 @@ -81,7 +81,7 @@ public: int read_header_carefully( Lzip_header & header, const bool ignore_errors ) { int sz = 0; - while( sz < Lzip_header::size && !finished() ) + while( sz < header.size && !finished() ) { header.data[sz] = buffer[pos]; if( ignore_errors && @@ -100,7 +100,7 @@ public: if( buffer[pos] != lzip_magic[0] ) { ++pos; continue; } reset_member_position(); Lzip_header h; - if( read_header_carefully( h, true ) == Lzip_header::size ) + if( read_header_carefully( h, true ) == header.size ) { header = h; return true; } } return false; @@ -381,6 +381,7 @@ public: unsigned crc() const { return crc_ ^ 0xFFFFFFFFU; } unsigned long long data_position() const { return partial_data_pos + pos; } - int decode_member( const Pretty_print & pp, const bool ignore_empty = true, - const bool ignore_marking = true ); + int decode_member( const Cl_options & cl_opts, const Pretty_print & pp ); + int decode_member() + { return decode_member( Cl_options(), Pretty_print( "" ) ); } }; -- cgit v1.2.3