Richard Nyberg
30601882e5
Whitespace.
пре 18 година
Richard Nyberg
00db1f1ced
Add function benc_strcmp.
пре 18 година
Richard Nyberg
ce0ef9d46b
Better message for ENOTENT.
пре 18 година
Richard Nyberg
a5ae3e120f
Some changes to the iobuf interface. Remove a debug assert from btpd_if.c and
make it act properly on iobuf errors.
пре 18 година
Richard Nyberg
763cbbb59f
Hook the new files to the build.
пре 18 година
Richard Nyberg
8695ecdf18
Pointers to different things need not be represented in the same way.
Use the fact that we only can store structs in the table to make the
complex pointer use safe. Unfortunately the equal and hash functions
need to take void * arguments.
пре 18 година
Richard Nyberg
848de36107
This file contains the definitions of the constants used in the btpd
interface.
пре 18 година
Richard Nyberg
a162d34982
Moved from ../cli.
пре 18 година
Richard Nyberg
13607e007a
Remove unused function bts_hashes.
пре 18 година
Richard Nyberg
334c94db46
There is no spoon^H^H^H^Htruct metainfo. Use struct mi_file instead.
пре 18 година
Richard Nyberg
cd0eb82f20
The metainfo code provided a load -> test -> struct metainfo interface.
The metainfo struct has been replaced by functions for qeurying specific
items from the torrent. In addition, the tests of the torrent data has
been improved.
пре 18 година
Richard Nyberg
c41c08adca
Moved from ../btpd/queue.h
пре 18 година
Richard Nyberg
a27913a47d
Add functions for conversions between binary data and ascii hex.
Add function for reading a whole file.
Enable printf format checking for some functions.
пре 18 година
Richard Nyberg
203d4148e4
Add a hashtable implementation.
пре 18 година
Richard Nyberg
c9ea09b1ad
Enable printf format type checking for buf_print.
пре 18 година
Richard Nyberg
47358cf420
Add function benc_strlen.
пре 18 година
Richard Nyberg
c865aa9254
Use c99 types conservatively to compile on OpenBSD. Also convert to or from
time_t via long.
пре 19 година
Richard Nyberg
1a82f0c154
White space.
пре 19 година
Richard Nyberg
634df68e31
Add functions find_btpd_dir.
пре 19 година
Richard Nyberg
8d05b64fa1
Remove unused function canon_path.
пре 19 година
Richard Nyberg
273294989e
Use benc_dget_mema instead of benc_dget_mem + malloc + bcopy.
пре 19 година
Richard Nyberg
b0c4f58f10
Use strtoul to parse length of strings.
пре 19 година
Richard Nyberg
d88c65e982
Added buf_swrite.
пре 19 година
Richard Nyberg
36a68e4b76
Check for failure to allocate memory.
пре 19 година
Richard Nyberg
af64140b1f
Remove som unused code I commited by mistake. Replace integer parse code
in benc_int with a call to strtoll.
пре 19 година
Richard Nyberg
01c92051d5
o Changed the benc_ api to make it easier to use.
o Lot of work on the cli and its communication with btpd.
пре 19 година
Richard Nyberg
6559fcb9a4
Make the buf api safe to continue to use even if an error has occured.
пре 19 година
Richard Nyberg
38418fcd2b
Add functions read_fully and write_fully. They are simpler alternatives to
read and write on blocking sockets.
пре 19 година
Richard Nyberg
59bed6ca87
Added vfsync and vfopen.
пре 19 година
Richard Nyberg
b2a877537a
White space.
пре 19 година
Richard Nyberg
a3933c0761
Unify the write and read structs. There was no good reason to keep them
separate. Improve the bts_seek so that it only calls close or lseek if
necessary. Otherwise it's a nop. Hide bts_seek and instead make the offset
explicit in calls to bts_get or bts_put.
пре 19 година
Richard Nyberg
1eea7650a2
Remove use of the ugly PRI* print macros.
пре 19 година
Richard Nyberg
2d2f8b0350
o Removed an unused function.
o Made bit field argument to has_bit const since the function
doesn't modify it.
пре 19 година
Richard Nyberg
b2bf61dbf7
Add and use rand_between.
пре 19 година
Richard Nyberg
c285b374f8
The mega whitespace patch.
Tabs have been converted to spaces and trailing whitespace have been removed.
I have fixed my emacs settings now :P
пре 19 година
Richard Nyberg
c11a57b8cb
Fix style. Remove unnecessary check for EINTR.
пре 19 година
Richard Nyberg
dd0d462afa
Import btpd-0.1.
git-svn-id: file:///home/rnyberg/svngit/btpd/releases/0.1@1 76a1f634-46fa-0310-9943-bd1476092a85
пре 19 година