libeech

BitTorrent library
git clone git://z3bra.org/libeech.git
Log | Files | Refs | README | LICENSE

commit 98d359fa4fc5e1b1f9ac22e8c92fbfe04abea44b
parent c10ccc735ed9378f312b3ccc5a7dd23fb0bf79e7
Author: z3bra <contactatz3bradotorg>
Date:   Mon,  9 Jul 2018 08:34:16 +0200

Set correct size for blocks bitfields

Diffstat:
libeech.h | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libeech.h b/libeech.h @@ -24,8 +24,8 @@ struct piece { int n; ssize_t sz; char blks[PCESIZ]; - char bf[PCENUM / 8 + !!(PCENUM % 8)]; - char rq[PCENUM / 8 + !!(PCENUM % 8)]; + char rq[PCESIZ / BLKSIZ + !!(PCESIZ % BLKSIZ)]; + char bl[PCESIZ / BLKSIZ + !!(PCESIZ % BLKSIZ)]; }; struct peer {