Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions proxy.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
fputs(info->ip,stdout);
fputs(info->port,stdout);
//code to connect to main server via this proxy server
int server_fd =0;
int server_fd = 0;
struct sockaddr_in server_sd;
// create a socket
server_fd = socket(AF_INET, SOCK_STREAM, 0);
Expand Down Expand Up @@ -100,9 +100,7 @@
signal(SIGPIPE,SIG_IGN);
// create a socket
if((proxy_fd = socket(AF_INET, SOCK_STREAM, 0)) < 0)
{
printf("\nFailed to create socket");
}
printf("Proxy created\n");
memset(&proxy_sd, 0, sizeof(proxy_sd));
// set socket variables
Expand Down