diff options
author | slvr <slvr@unsafeio.com> | 2013-08-12 14:44:59 +0100 |
---|---|---|
committer | slvr <slvr@unsafeio.com> | 2013-08-12 14:44:59 +0100 |
commit | c6b496d85b60e0177d0baa0f9cbbbc2c2199f924 (patch) | |
tree | 76c6d720baf1f6e8c83c467dc3001a93d1f9a952 /core | |
parent | f3511db29bb3f4a931c6efe66415981d73483262 (diff) |
Messenger Timer
Diffstat (limited to 'core')
-rw-r--r-- | core/Messenger.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/Messenger.c b/core/Messenger.c index e70b0378..e88206f3 100644 --- a/core/Messenger.c +++ b/core/Messenger.c | |||
@@ -670,18 +670,19 @@ static void doInbound(void) | |||
670 | } | 670 | } |
671 | } | 671 | } |
672 | 672 | ||
673 | #define PORT 33445 | ||
674 | |||
673 | /*Interval in seconds between LAN discovery packet sending*/ | 675 | /*Interval in seconds between LAN discovery packet sending*/ |
674 | #define LAN_DISCOVERY_INTERVAL 60 | 676 | #define LAN_DISCOVERY_INTERVAL 60 |
675 | 677 | ||
676 | /*Send a LAN discovery packet every LAN_DISCOVERY_INTERVAL seconds*/ | 678 | /*Send a LAN discovery packet every LAN_DISCOVERY_INTERVAL seconds*/ |
677 | static int LANdiscovery_timercallback(timer* t, void*) | 679 | static int LANdiscovery_timercallback(timer* t, void* ignore) |
678 | { | 680 | { |
679 | send_LANdiscovery(htons(PORT)); | 681 | send_LANdiscovery(htons(PORT)); |
680 | timer_start(t, LAN_DISCOVERY_INTERVAL); | 682 | timer_start(t, LAN_DISCOVERY_INTERVAL); |
681 | return 0; | 683 | return 0; |
682 | } | 684 | } |
683 | 685 | ||
684 | #define PORT 33445 | ||
685 | /* run this at startup */ | 686 | /* run this at startup */ |
686 | int initMessenger(void) | 687 | int initMessenger(void) |
687 | { | 688 | { |
@@ -715,7 +716,6 @@ void doMessenger(void) | |||
715 | doNetCrypto(); | 716 | doNetCrypto(); |
716 | doInbound(); | 717 | doInbound(); |
717 | doFriends(); | 718 | doFriends(); |
718 | LANdiscovery(); | ||
719 | } | 719 | } |
720 | 720 | ||
721 | /* returns the size of the messenger data (for saving) */ | 721 | /* returns the size of the messenger data (for saving) */ |