mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
On resume dumping a SSC tape get last written partition and file.
This commit is contained in:
@@ -31,6 +31,7 @@
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Threading;
|
||||
using DiscImageChef.CommonTypes;
|
||||
using DiscImageChef.CommonTypes.Extents;
|
||||
@@ -653,6 +654,23 @@ namespace DiscImageChef.Core.Devices.Dumping
|
||||
TapePartition currentTapePartition =
|
||||
new TapePartition {Number = currentPartition, FirstBlock = currentBlock};
|
||||
|
||||
if((canLocate || canLocateLong) && resume.NextBlock > 0)
|
||||
{
|
||||
currentBlock = resume.NextBlock;
|
||||
|
||||
currentTapeFile =
|
||||
(outputPlugin as IWritableTapeImage).Files.FirstOrDefault(f => f.LastBlock ==
|
||||
(outputPlugin as IWritableTapeImage)
|
||||
?.Files.Max(g => g.LastBlock));
|
||||
|
||||
currentTapePartition =
|
||||
(outputPlugin as IWritableTapeImage).TapePartitions.FirstOrDefault(p => p.LastBlock ==
|
||||
(outputPlugin as
|
||||
IWritableTapeImage)
|
||||
?.TapePartitions
|
||||
.Max(g => g.LastBlock));
|
||||
}
|
||||
|
||||
DateTime timeSpeedStart = DateTime.UtcNow;
|
||||
ulong currentSpeedSize = 0;
|
||||
double imageWriteDuration = 0;
|
||||
|
||||
Reference in New Issue
Block a user