diff options
author | irungentoo <irungentoo@gmail.com> | 2015-03-05 12:30:50 -0500 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2015-03-05 12:30:50 -0500 |
commit | ac7da66529884da7db6a72fdf20f02748b849396 (patch) | |
tree | 7266f382e5bc82ec516cfacfdf46616e884d6658 | |
parent | 85249111775bdcbeb946d60e59bd21b0d33e8e6d (diff) |
Code cleanups.
Fixed wrong variable used, removed useless elements of struct.
-rw-r--r-- | toxcore/Messenger.c | 4 | ||||
-rw-r--r-- | toxcore/Messenger.h | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/toxcore/Messenger.c b/toxcore/Messenger.c index 8bddd6bc..94cb93dd 100644 --- a/toxcore/Messenger.c +++ b/toxcore/Messenger.c | |||
@@ -826,7 +826,7 @@ void m_callback_statusmessage(Messenger *m, void (*function)(Messenger *m, uint3 | |||
826 | void *userdata) | 826 | void *userdata) |
827 | { | 827 | { |
828 | m->friend_statusmessagechange = function; | 828 | m->friend_statusmessagechange = function; |
829 | m->friend_statuschange_userdata = userdata; | 829 | m->friend_statusmessagechange_userdata = userdata; |
830 | } | 830 | } |
831 | 831 | ||
832 | void m_callback_userstatus(Messenger *m, void (*function)(Messenger *m, uint32_t, uint8_t, void *), void *userdata) | 832 | void m_callback_userstatus(Messenger *m, void (*function)(Messenger *m, uint32_t, uint8_t, void *), void *userdata) |
@@ -1654,7 +1654,7 @@ static int handle_packet(void *object, int i, uint8_t *temp, uint16_t len) | |||
1654 | 1654 | ||
1655 | if (m->friend_statusmessagechange) | 1655 | if (m->friend_statusmessagechange) |
1656 | m->friend_statusmessagechange(m, i, data_terminated, data_length, | 1656 | m->friend_statusmessagechange(m, i, data_terminated, data_length, |
1657 | m->friend_statuschange_userdata); | 1657 | m->friend_statusmessagechange_userdata); |
1658 | 1658 | ||
1659 | set_friend_statusmessage(m, i, data_terminated, data_length); | 1659 | set_friend_statusmessage(m, i, data_terminated, data_length); |
1660 | break; | 1660 | break; |
diff --git a/toxcore/Messenger.h b/toxcore/Messenger.h index 541894ab..67c2358d 100644 --- a/toxcore/Messenger.h +++ b/toxcore/Messenger.h | |||
@@ -236,8 +236,6 @@ struct Messenger { | |||
236 | void *friend_typingchange_userdata; | 236 | void *friend_typingchange_userdata; |
237 | void (*read_receipt)(struct Messenger *m, uint32_t, uint32_t, void *); | 237 | void (*read_receipt)(struct Messenger *m, uint32_t, uint32_t, void *); |
238 | void *read_receipt_userdata; | 238 | void *read_receipt_userdata; |
239 | void (*friend_statuschange)(struct Messenger *m, uint32_t, uint8_t, void *); | ||
240 | void *friend_statuschange_userdata; | ||
241 | void (*friend_connectionstatuschange)(struct Messenger *m, uint32_t, uint8_t, void *); | 239 | void (*friend_connectionstatuschange)(struct Messenger *m, uint32_t, uint8_t, void *); |
242 | void *friend_connectionstatuschange_userdata; | 240 | void *friend_connectionstatuschange_userdata; |
243 | void (*friend_connectionstatuschange_internal)(struct Messenger *m, uint32_t, uint8_t, void *); | 241 | void (*friend_connectionstatuschange_internal)(struct Messenger *m, uint32_t, uint8_t, void *); |