diff options
-rw-r--r-- | auto_tests/messenger_test.c | 3 | ||||
-rw-r--r-- | toxcore/Messenger.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/auto_tests/messenger_test.c b/auto_tests/messenger_test.c index f2b22967..cab238c8 100644 --- a/auto_tests/messenger_test.c +++ b/auto_tests/messenger_test.c | |||
@@ -206,7 +206,8 @@ START_TEST(test_getname) | |||
206 | ck_assert(getname(m, REALLY_BIG_NUMBER, name_buf) == -1); | 206 | ck_assert(getname(m, REALLY_BIG_NUMBER, name_buf) == -1); |
207 | 207 | ||
208 | memcpy(m->friendlist[0].name, &test_name[0], 3); | 208 | memcpy(m->friendlist[0].name, &test_name[0], 3); |
209 | getname(m, 0, &name_buf[0]); | 209 | m->friendlist[0].name_length = 4; |
210 | ck_assert(getname(m, 0, &name_buf[0]) == 4); | ||
210 | 211 | ||
211 | ck_assert(strcmp((char *)&name_buf[0], "foo") == 0); | 212 | ck_assert(strcmp((char *)&name_buf[0], "foo") == 0); |
212 | } | 213 | } |
diff --git a/toxcore/Messenger.h b/toxcore/Messenger.h index 0823891a..9d7f17dc 100644 --- a/toxcore/Messenger.h +++ b/toxcore/Messenger.h | |||
@@ -32,7 +32,7 @@ | |||
32 | #include "LAN_discovery.h" | 32 | #include "LAN_discovery.h" |
33 | 33 | ||
34 | #define MAX_NAME_LENGTH 128 | 34 | #define MAX_NAME_LENGTH 128 |
35 | #define MAX_STATUSMESSAGE_LENGTH 128 | 35 | #define MAX_STATUSMESSAGE_LENGTH 1007 |
36 | 36 | ||
37 | #define FRIEND_ADDRESS_SIZE (crypto_box_PUBLICKEYBYTES + sizeof(uint32_t) + sizeof(uint16_t)) | 37 | #define FRIEND_ADDRESS_SIZE (crypto_box_PUBLICKEYBYTES + sizeof(uint32_t) + sizeof(uint16_t)) |
38 | 38 | ||