1
0
Fork 0

Adding upstream version 0.25.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-17 21:27:24 +01:00
parent 4f5d0de2b2
commit 8853aa3bf2
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
33 changed files with 317 additions and 280 deletions

17
tarlz.h
View file

@ -1,5 +1,5 @@
/* Tarlz - Archiver with multimember lzip compression
Copyright (C) 2013-2023 Antonio Diaz Diaz.
Copyright (C) 2013-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
@ -419,7 +419,7 @@ enum Program_mode { m_none, m_append, m_compress, m_concatenate, m_create,
enum Solidity { no_solid, bsolid, dsolid, asolid, solid };
class Arg_parser;
struct Cl_options // command line options
struct Cl_options // command-line options
{
const Arg_parser & parser;
std::string archive_name;
@ -438,6 +438,7 @@ struct Cl_options // command line options
bool dereference;
bool filenames_given;
bool ignore_ids;
bool ignore_metadata;
bool ignore_overflow;
bool keep_damaged;
bool level_set; // compression level set in command line
@ -451,10 +452,10 @@ struct Cl_options // command line options
: parser( ap ), mtime( 0 ), uid( -1 ), gid( -1 ), program_mode( m_none ),
solidity( bsolid ), data_size( 0 ), debug_level( 0 ), level( 6 ),
num_files( 0 ), num_workers( -1 ), out_slots( 64 ), dereference( false ),
filenames_given( false ), ignore_ids( false ), ignore_overflow( false ),
keep_damaged( false ), level_set( false ), missing_crc( false ),
mtime_set( false ), permissive( false ), preserve_permissions( false ),
warn_newer( false ) {}
filenames_given( false ), ignore_ids( false ), ignore_metadata( false ),
ignore_overflow( false ), keep_damaged( false ), level_set( false ),
missing_crc( false ), mtime_set( false ), permissive( false ),
preserve_permissions( false ), warn_newer( false ) {}
void set_level( const int l ) { level = l; level_set = true; }
@ -469,7 +470,6 @@ inline void set_retval( int & retval, const int new_val )
const char * const bad_magic_msg = "Bad magic number (file not in lzip format).";
const char * const bad_dict_msg = "Invalid dictionary size in member header.";
const char * const corrupt_mm_msg = "Corrupt header in multimember file.";
const char * const trailing_msg = "Trailing data not allowed.";
const char * const bad_hdr_msg = "Corrupt or invalid tar header.";
const char * const gblrec_msg = "Error in global extended records.";
const char * const extrec_msg = "Error in extended records.";
@ -490,6 +490,7 @@ const char * const nfound_msg = "Not found in archive.";
const char * const seek_msg = "Seek error";
const char * const werr_msg = "Write error";
const char * const chdir_msg = "Error changing working directory";
const char * const intdir_msg = "Failed to create intermediate directory";
// defined in common.cc
unsigned long long parse_octal( const uint8_t * const ptr, const int size );
@ -505,7 +506,7 @@ bool show_member_name( const Extended & extended, const Tar_header header,
bool check_skip_filename( const Cl_options & cl_opts,
std::vector< char > & name_pending,
const char * const filename, const int chdir_fd = -1 );
bool make_path( const std::string & name );
bool make_dirs( const std::string & name );
// defined in common_mutex.cc
void exit_fail_mt( const int retval = 1 ); // terminate the program