Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
|
|
Also added some tests.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
nature of the change (add, del, name change).
tox.*, Messenger.*, group_chats.*:
- expand interface of callback by peernumber/change
groupchats.c:
- call callback in addpeer/delpeer/setnick with peernumber and flag
nTox.c:
- print_groupchatpeers(): print as many names on a line as possible, not one peer per line
- print_groupnamelistchange(): only print the change, if possible (i.e. "new peer", "peer's new name")
- added command "/p" to print the list of peers
|
|
|
|
|
|
|
|
These functions are akin to the tox_count_friendlist and tox_copy_friendlist, made available on the public API.
|
|
|
|
|
|
|
|
|
|
|
|
with Tox *tox in tox.c (which now includes the declarations from tox.h)
|
|
sendpacket() sets a timestamp if it happened
network.*:
- sendpacket(): checks result and on EAGAIN, stores time of this event
- networking_wait_prepare(): uses the time if set to check up to 500ms later for the socket to be writeable again
- networking_wait_cleanup(): clears the time if the socket was writeable
- fixed some accidental tabs
Messenger.*, tox.*:
- pass-through functions to reach networking_wait_cleanup()
- fixed some accidental tabs
|
|
To allow the actual waiting to run without any locking, split it into preparing the data it uses and the execution of the wait.
The caller must provide with the buffer to store whatever data it requires to wait.
Completely eliminates any reliance on the existence of anything but that data in the actual wait routine.
Also fixed a few argument type warnings inside LOGGING.
|
|
|
|
tox.*, Messenger.*, network.*;
- new function tox_wait() => waitMessenger() => networking_wait():
- waits for a given amount of time for any sort of socket activity
- mustn't change anything inside, mustn't poll or do other stuff
- the point is to be able to call this asynchronously from a second thread
- the outside shall follow up with an immediate tox_do() when there's socket activity
tox.*:
- allow inclusion of tox.h into tox.c, ensuring that the outside interface and the internal always match
util.c:
- squished a few warnings about questionable format strings
|
|
|
|
|
|
tox_get_friendlist() -> tox_copy_friendlist().
You now have to allocate your own memory to pass into tox_copy_friendlist.
To help with this, tox_count_friendlist() has been added to get the length
of the friend list.
|
|
|
|
Group message callback modified.
|
|
|
|
|
|
Group chats are not complete, they seem to work very well though.
This means that the functions will change.
|
|
- addr_resolv(_or_parse_ip)(): added an optional parameter to return both an IPv6 and an IPv4 address if requested address family was AF_UNSPEC
- logging of unhandled packets
DHT.c:
- bootstrap_from_address(): use the additional return from addr_resolv_or_parse_ip() to bootstrap in both network types at once
Lossless_UDP_testclient.c:
- main(): adapt to signature change of addr_resolve()
Messenger.c. LAN_discovery.h:
- lost a htons(), readded
- moved LAN_DISCOVERY_INTERVAL #define into LAN_discovery.h
LAN_discovery.c:
- added IPv4-in-IPv6 local address test
|
|
- #define'd tox's network port (as range)
- finally killed tox_new_ex() in favor of changing tox_new()'s signature
- renamed tox_bootstrap() to tox_bootstrap_from_ip()
network.h:
- #define'd tox's network port (as range)
- renamed SEND_NODES_EX to SEND_NODES_IPV6
- bind() loop uses #define'd port range
DHT.c:
- renamed SEND_NODES_EX to SEND_NODES_IPV6
- sending ipv6 node addresses even if can't use them ourselves
nTox.c:
- adapted to changed tox_new()
|
|
- tox_bootstrap_ex(), DHT_bootstrap_ex() renamed to tox_bootstrap_from_address(), DHT_bootstrap_from_address()
- (handle_)sendnodes_ex() renamed to (handle_)sendnodes_ipv6()
- only sending sendnodes_ipv6() if we're actually IPv6 enabled
- changed comments to conform better
nTox.c, Messenger_text.c, DHT_test.c, DHT_bootstrap.c:
- fallout from *_ex() to *_from_address()
DHT_bootstrap.c:
- corrected a potentially wrong info message
util.c:
- fixed logfile name: now (funcptr) => now() (number)
network.c:
- addead comment about the necessity of bind() to succeed
auto_test/messenger_test.c:
- defaulting ipv6enabled to TOX_ENABLE_IPV6_DEFAULT
LAN_discovery.c:
- slight cleanup and comments for clarity
|
|
- return to the caller if the string could be resolved into an IP
other/DHT_bootstrap.c, testing/*_test.c, testing/nTox.c:
- parse cmdline for --ipv4/--ipv6 switch to allow user a choice
util.h:
- proper old-style C-comment
|
|
|
|
|
|
- initialisation: argument added to enable/disable ipv6 as socket
Messenger_test.c:
- initialisation: ipv4 hardcoded for now
- delegating IP resolution to DHT_bootstrap_ex()
|
|
- second set of *_bootstrap_ex() functions to allow addresses instead of IPs
network.h:
- new message ID for sending/receiving IPv6 nodes
DHT.*:
- get_close_nodes():
- additional parameter to select which kind of nodes: IPv4 or IPv6
- sendnodes()/handle_sendnodes():
- the IPv4 message must remain intact even when the Node_format structure (which embeds IP_Port) is expanded
- added Node4_format to keep the structure "alive"
- copying in/out of wider to smaller format required in sendnodes()/handle_sendnodes()
- switch of Node_format from Node4_format to Node46_format by define
|
|
|
|
|
|
By default libsodium is used. Only if --enable-nacl is specified, then
nacl will be used instead of libsodium.
Pass locations of nacl headers and libraries by using the following
options:
--with-nacl-headers=/home/me/somewhere/nacl-20110221/build/469/include/amd64/
--with-nacl-libs=/home/me/somewhere/nacl-20110221/build/469/lib/amd64/
|