aboutsummaryrefslogtreecommitdiff
path: root/lib/UnrarXLib/volume.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/UnrarXLib/volume.cpp')
-rw-r--r--lib/UnrarXLib/volume.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/UnrarXLib/volume.cpp b/lib/UnrarXLib/volume.cpp
index 1f4d5e3ffb..b24e98bd61 100644
--- a/lib/UnrarXLib/volume.cpp
+++ b/lib/UnrarXLib/volume.cpp
@@ -15,6 +15,7 @@ bool MergeArchive(Archive &Arc,ComprDataIO *DataIO,bool ShowFileName,char Comman
Log(Arc.FileName,St(MDataBadCRC),hd->FileName,Arc.FileName);
}
+ Int64 PrevFullUnpSize = hd->FullUnpSize;
Int64 PosBeforeClose=Arc.Tell();
Arc.Close();
@@ -144,6 +145,13 @@ bool MergeArchive(Archive &Arc,ComprDataIO *DataIO,bool ShowFileName,char Comman
}
}
#endif
+
+ if (hd->FullUnpSize == 0)
+ {
+ // some archives only have correct UnpSize in the first volume
+ hd->FullUnpSize = PrevFullUnpSize;
+ }
+
if (DataIO!=NULL)
{
if (HeaderType==ENDARC_HEAD)