summaryrefslogtreecommitdiffstats
path: root/extended.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2020-08-08 17:10:19 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2020-08-08 17:11:19 +0000
commite9232deb17df1ba9d36920e1d3444d34ad6ec18e (patch)
tree86f970c2e20f2d35845918f26f55bedffcd5f82c /extended.cc
parentReleasing debian version 0.16-4. (diff)
downloadtarlz-e9232deb17df1ba9d36920e1d3444d34ad6ec18e.tar.xz
tarlz-e9232deb17df1ba9d36920e1d3444d34ad6ec18e.zip
Merging upstream version 0.17.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'extended.cc')
-rw-r--r--extended.cc29
1 files changed, 16 insertions, 13 deletions
diff --git a/extended.cc b/extended.cc
index 0e647c6..d03494f 100644
--- a/extended.cc
+++ b/extended.cc
@@ -1,18 +1,18 @@
-/* Tarlz - Archiver with multimember lzip compression
- Copyright (C) 2013-2019 Antonio Diaz Diaz.
+/* Tarlz - Archiver with multimember lzip compression
+ Copyright (C) 2013-2020 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
- the Free Software Foundation, either version 2 of the License, or
- (at your option) any later version.
+ 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
+ the Free Software Foundation, either version 2 of the License, or
+ (at your option) any later version.
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#define _FILE_OFFSET_BITS 64
@@ -32,6 +32,8 @@
namespace {
+const CRC32 crc32c( true );
+
unsigned decimal_digits( unsigned long long value )
{
unsigned digits = 1;
@@ -280,7 +282,8 @@ void Extended::fill_from_ustar( const Tar_header header )
/* Returns file size from record or from ustar header, and resets file_size_.
- Used for fast parsing of headers in uncompressed archives. */
+ Used for fast parsing of headers in uncompressed archives.
+*/
long long Extended::get_file_size_and_reset( const Tar_header header )
{
const long long tmp = file_size_;