Skip to content

a simple TCP Server Client application in C where multiple client computers participate in the chat along with a common server. Here, a client sends some text messages to the server along with the recipient’s ID in a user defined port (of your choice). On reception of that message, server forwards the message to the respective client.

ghostmk/tcp_chat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

tcp_chat

Compile both the files with:

gcc server.c -o server -lpthread
gcc client.c -o client -lpthread

First run the server and specify a port as an argument e.g. 8080

./server 8080

Then run the client and specify the IP Address of the server and the port as the argument, if server is running locally give localhost as IP i.e. 127.0.0.1

./client 127.0.0.1 8080

About

a simple TCP Server Client application in C where multiple client computers participate in the chat along with a common server. Here, a client sends some text messages to the server along with the recipient’s ID in a user defined port (of your choice). On reception of that message, server forwards the message to the respective client.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages