summaryrefslogtreecommitdiff
path: root/toxcore/Messenger.h
diff options
context:
space:
mode:
authorirungentoo <irungentoo@gmail.com>2013-09-22 14:14:53 -0400
committerirungentoo <irungentoo@gmail.com>2013-09-22 14:14:53 -0400
commit8b5d9dc13e5b5fe66f47701aec57ae7b04345be3 (patch)
tree80caf6a1cf7729078dee1bb8bb59d9753a0f36e8 /toxcore/Messenger.h
parent64150f4bde73f4b4748a3e46664a2930a3635054 (diff)
parentcb68be00b0bb8802da94b877a24e68ee35b5658a (diff)
Merge branch 'patch-9001' of https://github.com/stal888/ProjectTox-Core into stal888-patch-9001
Diffstat (limited to 'toxcore/Messenger.h')
-rw-r--r--toxcore/Messenger.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/toxcore/Messenger.h b/toxcore/Messenger.h
index 78580dc0..81e661e1 100644
--- a/toxcore/Messenger.h
+++ b/toxcore/Messenger.h
@@ -456,6 +456,18 @@ void Messenger_save(Messenger *m, uint8_t *data);
456/* Load the messenger from data of size length. */ 456/* Load the messenger from data of size length. */
457int Messenger_load(Messenger *m, uint8_t *data, uint32_t length); 457int Messenger_load(Messenger *m, uint8_t *data, uint32_t length);
458 458
459/* Return the number of friends in the instance m.
460 * You should use this to determine how much memory to allocate
461 * for copy_friendlist. */
462size_t count_friendlist(Messenger *m);
463
464/* Copy a list of valid friend IDs into the array out_list.
465 * If out_list is NULL, returns -1.
466 * Otherwise, returns the number of elements copied.
467 * If the array was too small, the contents
468 * of out_list will be truncated to list_size. */
469size_t copy_friendlist(Messenger *m, int *out_list, size_t list_size);
470
459/* Allocate and return a list of valid friend id's. List must be freed by the 471/* Allocate and return a list of valid friend id's. List must be freed by the
460 * caller. 472 * caller.
461 * 473 *