mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-23 01:33:02 +01:00
Merge remote-tracking branch 'upstream/master' into ipv6.init_connection
This commit is contained in:
commit
560e6be66b
@ -136,7 +136,7 @@ int serverlist_load()
|
||||
char line[MAXLINE];
|
||||
while (fgets(line, sizeof(line), fp) && linecnt < MAXSERVERS) {
|
||||
if (strlen(line) > MINLINE) {
|
||||
char *name = strtok(server, " ");
|
||||
char *name = strtok(line, " ");
|
||||
char *port = strtok(NULL, " ");
|
||||
char *key_ascii = strtok(NULL, " ");
|
||||
/* invalid line */
|
||||
@ -149,7 +149,7 @@ int serverlist_load()
|
||||
|
||||
uint8_t *key_binary = hex_string_to_bin(key_ascii);
|
||||
memcpy(keys[linecnt], key_binary, TOX_CLIENT_ID_SIZE);
|
||||
free(binary_string);
|
||||
free(key_binary);
|
||||
|
||||
linecnt++;
|
||||
}
|
||||
@ -166,7 +166,7 @@ int serverlist_load()
|
||||
|
||||
int init_connection_helper(Tox *m, int linenumber)
|
||||
{
|
||||
return tox_bootstrap_from_address(m, servers[linenumber, TOX_ENABLE_IPV6_DEFAULT,
|
||||
return tox_bootstrap_from_address(m, servers[linenumber], TOX_ENABLE_IPV6_DEFAULT,
|
||||
ports[linenumber], keys[linenumber]);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user