This project has been created as part of the 42 curriculum by anashwan
minitalk is a small project focused on inter-process communication (IPC) using UNIX signals. It consists of two programs:
- server
- client
The client sends a string message to the server bit by bit using UNIX signals. The server receives these signals, reconstructs the original message, and prints it to standard output.
The goal of this project is to introduce and strengthen understanding of the following core concepts:
A process is an instance of a program currently running on the system. When a program is executed, the operating system creates a process, loads it into memory, and assigns it several properties. One of the most important is the Process ID (PID), a unique identifier used to reference and interact with the process. Signals can be sent to a specific process using its PID.
A signal is a standardized message sent to a process to notify it that a specific event has occurred. When a process receives a signal, its execution is interrupted so the signal can be handled.
- Some signals can be handled or overridden by the program.
- Others (such as
SIGKILL) cannot be handled and always terminate the process. - UNIX also provides user-defined signals, which are used in this project to transmit data between processes.
To build both the client and the server, run:
make- Start the server:
./server-
The server will display its PID.
-
In a separate terminal, send a message using the client:
./client <pid> <message>- Remove object files:
make clean- Remove object files and executables:
make fclean- Codequoi — Sending and intercepting signals in C
- GeeksforGeeks — Processes in Linux/UNIX
- Wikipedia — Signal (IPC)
- Wikipedia — Inter-process communication
- Wikipedia — Asynchrony (computer programming)
AI tools were used for:
- High-level explanations of UNIX signals and IPC concepts
- Debugging guidance and reasoning about signal-based communication