Skip to content

Commit

Permalink
FIX Host buffer para permitir IPv6
Browse files Browse the repository at this point in the history
  • Loading branch information
GabrielVanLoon committed Jul 20, 2020
1 parent b7317fb commit 729b12a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client_src/chat.h
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@
*/
typedef struct _relay_chat {
// atributos de conexão
char sserver[24], sport[24];
char sserver[60], sport[30];
struct hostent *server;
int port;
int network_socket;
Expand Down
2 changes: 1 addition & 1 deletion client_src/codec.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
char temp_host[120];
char temp_port[120];

int nro_itens = sscanf(cmd, "/connect %119s %119s", temp_host, temp_port);
int nro_itens = sscanf(cmd, "/connect %59s %29s", temp_host, temp_port);

if(nro_itens >= 1) {
strcpy(host, temp_host);
Expand Down

0 comments on commit 729b12a

Please sign in to comment.