Richard Nyberg
c9ea09b1ad
Enable printf format type checking for buf_print.
hace 18 años
Richard Nyberg
47358cf420
Add function benc_strlen.
hace 18 años
Richard Nyberg
c4379cdfb9
Send keepalives.
hace 18 años
Richard Nyberg
1f4ef6cb15
Reduce the number of HAVE messages sent by only sending them to peers missing
the piece. Remove seeder peers when our download is finished and remove peers
who doesn't show any interest for a long time when we're seeding.
hace 18 años
Richard Nyberg
e0877d2870
Torrents that were active when btpd was last killed will now be automatically
started when btpd starts. The new '--empty-start' option turns this off.
hace 18 años
Richard Nyberg
251b5d2e18
Add a delay for contacting the same announce url. This way we don't spam
a tracker with connections even if we add a lot of torrents with the same
tracker at the same time.
hace 18 años
Richard Nyberg
eb1581a673
Change version to 0.11 and document the changes.
hace 18 años
Richard Nyberg
7ce1098dff
Remove the events for a peer's socket before closing it. At least the epoll
libevent backend didn't like the fd to be closed. Reported by Ludvig Omholt.
hace 18 años
Richard Nyberg
45ceb46c42
Change version to 0.10 and document the changes.
hace 18 años
Richard Nyberg
336a4d4c02
Changed the help for the '--ipcprot' option.
hace 18 años
Richard Nyberg
2e073c13f2
Truncate the pid file when opening it. Now it actually will contain the pid
of the btpd process :)
hace 18 años
Richard Nyberg
2285473192
Make sure btpd_dir contains an absolute path. If btpd was started with
'-d some/releative/path' it would fail to set up the ipc socket correctly.
Reported by Arnaud Bergeron.
hace 18 años
Richard Nyberg
7810b15cfd
Add the '--ipcprot' option to change the protection mode of the command
socket. From Arnaud Bergeron.
hace 18 años
Richard Nyberg
2a462baead
Btpd could be DOS'ed by incoming connections that never send any data.
Strangely such connections are not entirely uncommon. Added a hand shake
time out of 60 seconds to resolve this.
Added a peer_on_tick function which is used to monitor peers for different
timeouts. Timestamps are compared against the reborn btpd_seconds.
The issue has been reported by Ludvig Omholt and Arnaud Bergeron.
hace 18 años
Richard Nyberg
cfb37a5227
Split out common code for btpd_log and btpd_err.
hace 18 años
Richard Nyberg
ed56df9e56
Use the new functions btpd_ev_(add|del) instead of calling event_(add|del)
directly. Failure to add or delete an event is treated as a fatal error.
hace 18 años
Richard Nyberg
368bafd8a6
Fix type mismath. From Arnaud Bergeron.
hace 18 años
Richard Nyberg
3c5beeaa0e
Changes for 0.9.
hace 19 años
Richard Nyberg
a0985012a1
Version 0.9.
hace 19 años
Richard Nyberg
4e6f095c41
Cut off decimals after the first tenth percent so printf doesn't round
the percentage upwards. Ie. Display 99.9%, not 100.0%, even if we have
99.98% of the content.
hace 19 años
Richard Nyberg
db49763849
The previous commit was a bit over zealous; the block field should not be
cleared for a failed piece in the full torrent test. This also fixes a bug
where the content byte count wasn't decreased for failed pieces.
hace 19 años
Richard Nyberg
b72b6bb8ba
The code for testing content that has potentially been modified between btpd
runs was quite broken. Pieces stayed marked as ok event though the hash test
failed for pieces in modified files. Oops!
hace 19 años
Richard Nyberg
cdb471d0ac
Fix a bug from the last commit: shared messages for endgame requests could
be placed at the wrong index in the array.
hace 19 años
Richard Nyberg
9f4070eeb8
There's now one list with requests per piece instead of one per block. The
network buffers for requests are now allocated as they're needed. Before
they were allocated at the same time as their corresponding piece. This
lowers btpd's memory consumption.
hace 19 años
Richard Nyberg
6214255bbb
Safer code for net_read32 and net_write32. It may have been possible for them
to cause failure on some architectures because of unaligned fetch/write of
integers.
hace 19 años
Richard Nyberg
a1f2f9faae
Two changes to stat output:
1. Show the number of torrents with tracker errors on the total status line.
2. Show the torrent status character on the status line instead of the name
line. This only has effect when the '-i' flag is given.
hace 19 años
Richard Nyberg
f219b47a33
Set default value of cm_alloc_size to 2MB.
hace 19 años
Richard Nyberg
1b3c4e7c05
Set its rates to zero when stopping a torrent.
hace 19 años
Richard Nyberg
4382442f11
Rewrote the README with changes for 0.8..
hace 19 años
Richard Nyberg
2d696edbb6
Changes for 0.8.
hace 19 años
Richard Nyberg
eb85993c8c
Don't allow a negative cm_alloc_size to wreak havoc.
hace 19 años
Richard Nyberg
2ee5eed062
Return possible error message in the http result. Log the error in the
tracker code.
hace 19 años
Richard Nyberg
61752ade71
Change preallocation default to 2048. 1 may be a little low.
hace 19 años
Richard Nyberg
bcac74d138
Safer type use.
hace 19 años
Richard Nyberg
b61b04f258
Fix typo.
hace 19 años
Richard Nyberg
b2271a4851
Add a note on the ACX_PTHREAD macro license.
hace 19 años
Richard Nyberg
a48375dae5
I don't quite like this file. I think I will use the trac site to keep
this kind of information instead.
hace 19 años
Richard Nyberg
88aa2eeb63
Better log message.
hace 19 años
Richard Nyberg
c577f4dbff
Better log message.
hace 19 años
Richard Nyberg
cd1164ef02
Be careful not to stop the sub struct if they haven't been started. Also
be careful so that we don't operate on a dead torrent.
hace 19 años
Richard Nyberg
9decd35436
Oops! Forgot to free some memory.
hace 19 años
Richard Nyberg
eef8a3a837
Call realpath after creating the dir. At least on linux the call to realpath
may fail if the last path component doesn't exist.
hace 19 años
Richard Nyberg
c865aa9254
Use c99 types conservatively to compile on OpenBSD. Also convert to or from
time_t via long.
hace 19 años
Richard Nyberg
9732ed1981
Glibc needs sys/file.h for flock.
hace 19 años
Richard Nyberg
b43809ba55
Mostly name changes. Add a missing include. Changed the torrent status
characters displayed by btcli.
hace 19 años
Richard Nyberg
bf75d6af1c
Glibc doesn't support locking in open. Use flock after open instead.
hace 19 años
Richard Nyberg
7dedb28137
Put the ACX_PTHREAD macro from the Autoconf macro archive in acinclude.m4.
Build btpd with pthreads.
hace 19 años
Richard Nyberg
59c62b3eb0
Change the downloaders option to max-uploads. I find it much less confusing
that way :P
hace 19 años
Richard Nyberg
31f0e727df
Add torrent_name function and use it.
hace 19 años
Richard Nyberg
c069f03a8e
btcli stat now takes file arguments to only include stats for the given
torrents.
hace 19 años