Age | Commit message (Collapse) | Author |
|
uint is not a valid type on Windows. It's also not a valid type in C, but Linux
and OSX define it somewhere. We can't rely on its existence.
|
|
- This PR also adds a DEBUG cmake option that enables -DTOX_DEBUG.
- We also remove `-Wall`, because there are too many warnings, and nobody really
looks at them at the moment. We'll see about fixing them soon. We'll also want
to enable `-Werror` at some point.
- Finally, this PR enables `-O3` to make sure toxcore still works correctly
under heavy compiler optimisations.
|
|
|
|
|
|
|
|
assoc->self_client_id is always true, therefore we can remove it from that if" -m "The if thus asserts !assoc->self_hash, so we can elide the immediately following if (!assoc->self_hash)
|
|
|
|
|
|
|
|
|
|
#if 0 the content of toxav/msi.c : int stringify_message(MSIMessage
*msg, char *dest)
This function has no effect and does not seem to be used for actively
waiting.
Fix various other style errors, reduce scope when possible, avoid
redundant writes, clarify operator priorities, etc.
|
|
|
|
|
|
|
|
Removed some useless code from toxcore.
Astyled core code with new version of astyle.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fix a code cleanup.
|
|
https://github.com/FullName/ProjectTox-Core into FullName-assoc-refresh-distant-data
|
|
DHT.c:
- get_close_nodes():
- allow two 'indirect' nodes ('indirect' as in distant from us and therefore not tested regularly, "bad")
- be consequent when testing for NULLed results, pack nodes_list dense
- (logging) dump number of found entries from assoc
- returnedip_ports():
- fix code cleanup, the entry to be added is about the node we were told, not about the node who told us
assoc.c:
- Assoc_get_close_entries(): break from loops as soon as a marking-invalid-node is hit
|
|
|
|
|
|
Changed default assoc so that it behaves correctly.
|
|
https://github.com/FullName/ProjectTox-Core into FullName-sendnodes-with-assoc
|
|
DHT.c:
- get_close_nodes(): use assoc to find nodes for the requested reference id
- handle_sendnodes*(): set a proper timestamp for "heard" nodes
assoc.*:
- expand Assoc_close_entries by flags for additional restrictions for search
- Assoc_get_close_entries(): honor the new flags
- new_Assoc() prime handling: min. prime is now 5 instead of 3, and up to 25 is handled directly
- Assoc_status(): added address family for seen/heard, print of hash is now fixed width
|
|
building toxcore
|
|
|
|
entries).
id_hash() was not at all working as expected for very small bucket size (when (size / 4) was zero). Simplified to be trivially correct.
Also added a used flag on adding an entry, which is set by callers if they have that association in active use. Those get priority over unused entries on collision.
Fleshed out test to be at least elementary useful.
Each group chat now uses an own, small assoc (80 entries).
|
|
Besides acknowledging timeouts, the module isn't trying to do anything fancy with the data besides storing and retrieving.
|