Skip to content

Commit

Permalink
working on compression
Browse files Browse the repository at this point in the history
  • Loading branch information
Sidray-Infinity committed Apr 6, 2020
1 parent 27972e5 commit 6cd5f02
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,3 +175,5 @@ The aim of this project is to provide a file sharing system, among the peers con
## Finalization
- Remove the clear table commands that is executed, everytime the server starts.
- Adding the GUI looks close to impossible. Quite the unexpected. It wants me to conver this while thing to a library!
- Add compression: Looking into arithmetic encoding.
- Add encryption.
9 changes: 6 additions & 3 deletions client.c
Original file line number Diff line number Diff line change
Expand Up @@ -417,9 +417,12 @@ int main(int args, char *argv[]) {

self_bind = bind(udp_sockid, (struct sockaddr*)&self, sizeof(self));
}

char serv_ip[20];
bzero(serv_ip, 20);
printf("Enter server IP:\n");
fgets(serv_ip, 20, stdin);
struct sockaddr_in addr;
addr.sin_addr.s_addr = INADDR_ANY;
addr.sin_addr.s_addr = htonl(serv_ip);
addr.sin_family = AF_INET;
addr.sin_port = htons(SERVER_PORT);

Expand Down Expand Up @@ -938,4 +941,4 @@ int main(int args, char *argv[]) {
close(sock_id);
close(udp_sockid);
return 0;
}
}

0 comments on commit 6cd5f02

Please sign in to comment.