aboutsummaryrefslogtreecommitdiffstats
path: root/swarm
diff options
context:
space:
mode:
Diffstat (limited to 'swarm')
-rw-r--r--swarm/bmt/bmt.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/swarm/bmt/bmt.go b/swarm/bmt/bmt.go
index 1a141047a..97e0e141e 100644
--- a/swarm/bmt/bmt.go
+++ b/swarm/bmt/bmt.go
@@ -318,7 +318,7 @@ func (h *Hasher) Sum(b []byte) (s []byte) {
// with every full segment calls writeSection in a go routine
func (h *Hasher) Write(b []byte) (int, error) {
l := len(b)
- if l == 0 {
+ if l == 0 || l > 4096 {
return 0, nil
}
t := h.getTree()