check_port(name);
- fprintf(stderr, "Invitation succesfully accepted.\n");
- shutdown(sock, SHUT_RDWR);
- success = true;
-
ask_netname:
if(ask_netname) {
fprintf(stderr, "Enter a new netname: ");
return true;
}
+
static bool invitation_send(void *handle, uint8_t type, const char *data, size_t len) {
while(len) {
int result = send(sock, data, len, 0);
case 1:
return finalize_join();
+ case 2:
+ fprintf(stderr, "Invitation succesfully accepted.\n");
+ shutdown(sock, SHUT_RDWR);
+ success = true;
+ break;
+
default:
return false;
}
fclose(f);
logger(DEBUG_CONNECTIONS, LOG_INFO, "Key succesfully received from %s (%s)", c->name, c->hostname);
+ sptps_send_record(&c->sptps, 2, data, 0);
return true;
}