diff options
author | irungentoo <irungentoo@gmail.com> | 2014-05-30 23:01:17 -0400 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2014-05-30 23:01:17 -0400 |
commit | 89bf08287dce89455726f49215dd1f552b086886 (patch) | |
tree | bd1c6f0c255f968103d117d50828aae4f196ea44 /toxcore/tox.c | |
parent | ab44440f37e90468467028da94287ed0c94a7ec7 (diff) |
Renamed tox_do_run_interval to tox_do_interval.
tox_do_interval now returns a time in ms based on how much action
is going on in net_crypto.
Diffstat (limited to 'toxcore/tox.c')
-rw-r--r-- | toxcore/tox.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/toxcore/tox.c b/toxcore/tox.c index f9df7860..b8c15a39 100644 --- a/toxcore/tox.c +++ b/toxcore/tox.c | |||
@@ -782,14 +782,15 @@ int tox_isconnected(Tox *tox) | |||
782 | return DHT_isconnected(m->dht); | 782 | return DHT_isconnected(m->dht); |
783 | } | 783 | } |
784 | 784 | ||
785 | /* Return the optimal interval in milliseconds between tox_do() calls. | 785 | /* Return the time in milliseconds before tox_do() should be called again |
786 | * This function should be called after every tox_do() call for best performance. | 786 | * for optimal performance. |
787 | * | ||
788 | * returns time (in ms) before the next tox_do() needs to be run on success. | ||
787 | */ | 789 | */ |
788 | uint32_t tox_do_run_interval(Tox *tox) | 790 | uint32_t tox_do_interval(Tox *tox) |
789 | { | 791 | { |
790 | Messenger *m = tox; | 792 | Messenger *m = tox; |
791 | //TODO | 793 | return messenger_run_interval(m); |
792 | return 10; | ||
793 | } | 794 | } |
794 | 795 | ||
795 | /* Run this at startup. | 796 | /* Run this at startup. |