fix line skip counter #1
cargo devel CI / cargo CI (push) Successful in 1m23s Details

This commit is contained in:
Christoph J. Scherr 2024-02-01 23:27:28 +01:00
parent 7bea6ede4c
commit 1cb492d90a
Signed by: PlexSheep
GPG Key ID: 7CDD0B14851A08EF
1 changed files with 4 additions and 2 deletions

View File

@ -2,7 +2,7 @@
use std::io::{prelude::*, Read, SeekFrom};
use anyhow::{bail, Result};
use anyhow::Result;
use libpt::bintols::display::humanbytes;
use libpt::log::{debug, error, trace, warn};
@ -137,7 +137,7 @@ impl Hedu {
"******** {LINE_SEP_VERT} {:<49}",
format!(
"(repeats {} lines)",
self.data_idx - start_line / (BYTES_PER_LINE) + 1
(self.data_idx - start_line / (BYTES_PER_LINE) + 1) / BYTES_PER_LINE
)
);
if self.chars {
@ -206,6 +206,8 @@ impl Hedu {
self.display();
Ok(())
}
/// adjust the counters of the hedu struct, adding self.len
#[inline]
fn adjust_counters(&mut self) {
self.rd_counter += self.len;