diff options
Diffstat (limited to 'testing/Messenger_test.c')
-rw-r--r-- | testing/Messenger_test.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/testing/Messenger_test.c b/testing/Messenger_test.c index f38eb962..6ad5c7dd 100644 --- a/testing/Messenger_test.c +++ b/testing/Messenger_test.c | |||
@@ -38,6 +38,7 @@ | |||
38 | */ | 38 | */ |
39 | 39 | ||
40 | #include "../core/Messenger.h" | 40 | #include "../core/Messenger.h" |
41 | #include "../core/misc_tools.h" | ||
41 | 42 | ||
42 | #ifdef WIN32 | 43 | #ifdef WIN32 |
43 | 44 | ||
@@ -50,22 +51,6 @@ | |||
50 | 51 | ||
51 | #endif | 52 | #endif |
52 | 53 | ||
53 | //TODO: rewrite | ||
54 | unsigned char * hex_string_to_bin(char hex_string[]) | ||
55 | { | ||
56 | size_t len = strlen(hex_string); | ||
57 | unsigned char * val = malloc(len); | ||
58 | char * pos = hex_string; | ||
59 | int i=0; | ||
60 | while(i < len) | ||
61 | { | ||
62 | sscanf(pos,"%2hhx",&val[i]); | ||
63 | pos+=2; | ||
64 | i++; | ||
65 | } | ||
66 | return val; | ||
67 | } | ||
68 | |||
69 | void print_request(uint8_t * public_key, uint8_t * data, uint16_t length) | 54 | void print_request(uint8_t * public_key, uint8_t * data, uint16_t length) |
70 | { | 55 | { |
71 | printf("Friend request recieved from: \n"); | 56 | printf("Friend request recieved from: \n"); |