diff options
author | axtloss <axtlos@getcryst.al> | 2024-02-04 15:14:49 +0100 |
---|---|---|
committer | axtloss <axtlos@getcryst.al> | 2024-02-04 15:14:49 +0100 |
commit | 5b3826f5de82eb3dcb43bcb85261cd56e298668a (patch) | |
tree | b5a10c89fbc2b3a1123aa19b770305e5e3de8854 /core/verification.go | |
parent | 71cc54810fdb51e428b83a37ff89d54a6cc3d8c8 (diff) | |
download | fsverify-5b3826f5de82eb3dcb43bcb85261cd56e298668a.tar.gz fsverify-5b3826f5de82eb3dcb43bcb85261cd56e298668a.tar.bz2 |
Repeated block verification
Diffstat (limited to '')
-rw-r--r-- | core/verification.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/verification.go b/core/verification.go index b48c0b7..7c427c0 100644 --- a/core/verification.go +++ b/core/verification.go @@ -11,6 +11,8 @@ import ( "github.com/tarm/serial" ) +var TotalReadBlocks int = 0 + func fileReadKey() (string, error) { if _, err := os.Stat(config.KeyLocation); os.IsNotExist(err) { return "", fmt.Errorf("Key location %s does not exist", config.KeyLocation) @@ -98,6 +100,7 @@ func ReadBlock(node Node, part *bufio.Reader) ([]byte, error) { return []byte{}, err } block, err = part.Peek(blockSize) + TotalReadBlocks = TotalReadBlocks + blockSize return block, err } |