diff --git a/LICENSE b/LICENSE index 7a3094a..4eeca54 100644 --- a/LICENSE +++ b/LICENSE @@ -1,11 +1,14 @@ -DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE -Version 2, December 2004 + DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE + Version 2, December 2004 -Copyright (C) 2004 Sam Hocevar + Copyright (C) 2004 Sam Hocevar -Everyone is permitted to copy and distribute verbatim or modified copies of this license document, and changing it is allowed as long as the name is changed. + Everyone is permitted to copy and distribute verbatim or modified + copies of this license document, and changing it is allowed as long + as the name is changed. -DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. You just DO WHAT THE FUCK YOU WANT TO. + diff --git a/README.md b/README.md deleted file mode 100644 index 19fe113..0000000 --- a/README.md +++ /dev/null @@ -1,2 +0,0 @@ -# deltarune-irc - diff --git a/main.c b/main.c index 55afbfe..4077c0e 100644 --- a/main.c +++ b/main.c @@ -81,9 +81,6 @@ void recvinfo(int fd) { } } } - - else if (irc_status == IRCC_CONNECTED) - return; } } @@ -125,21 +122,12 @@ int main(void) { //Register IRCC_register(&client, NICK); - //Recv motd and join in channel - recvinfo(fd); sleep(5); for (size_t i = 0; i < sizeof(channels) / sizeof(char *); i++) { if (channels[i] == NULL) break; - size_t join_size = strlen("JOIN \r\n") + strlen(channels[i]) + 1; - char *tmp = malloc(join_size); - if (tmp == NULL) - die("malloc retured NULL"); - - snprintf(tmp, join_size, "JOIN %s\r\n", channels[i]); - send(client.socket, tmp, join_size, 0); - free(tmp); + IRCC_join(&client, channels[i], NULL); } recvinfo(fd);