From f4fff4736580d76892987ceaef7c199d52624bb2 Mon Sep 17 00:00:00 2001 From: Martin Hebnes Pedersen Date: Mon, 1 Apr 2019 21:54:59 +0200 Subject: [PATCH] Fix panic in Fragment.DataBlocks() duo to typo store vs stored --- data.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data.go b/data.go index 2f3eacb..049f812 100644 --- a/data.go +++ b/data.go @@ -164,7 +164,7 @@ func (df *DataFragment) DataBlocks(dataType uint8, confirm bool) ([]*DataBlock, store := int(block.Length) if df.Stored-stored < store { - store = df.Stored - store + store = df.Stored - stored } copy(block.Data, df.Data[stored:stored+store]) stored += store