A basic client-server communication project with a C server and a Python client.
server.c: Handles incoming connections, messages, and uses threading for concurrency.client.py: Connects to the C server, sends messages, and allows clean disconnection.
- Compile
server.con your terminal using a C compiler (e.g.,gcc -o server server.c -lpthread). - Run
./serverto start the C server. - Run
python client.pyto start the Python client. - Enter messages in the client to send them to the C server and other connected clients.
- The C server is multithreaded, allowing multiple client connections.
- Modify the server's code to include additional features or configurations.
- Use command-line arguments in the client to specify server address, port, etc.