SIGINT (POSIX)
Encyclopedia
On POSIX
-compliant platforms, SIGINT is the signal
sent to a process
by its controlling terminal when a user wishes to interrupt the process. In source code
, SIGINT is a symbolic constant
defined in the header file
presses the interrupt the running process key — typically Control-C, but on some systems, the "delete
" character or "break
" key.
POSIX
POSIX , an acronym for "Portable Operating System Interface", is a family of standards specified by the IEEE for maintaining compatibility between operating systems...
-compliant platforms, SIGINT is the signal
Signal (computing)
A signal is a limited form of inter-process communication used in Unix, Unix-like, and other POSIX-compliant operating systems. Essentially it is an asynchronous notification sent to a process in order to notify it of an event that occurred. When a signal is sent to a process, the operating system...
sent to a process
Process (computing)
In computing, a process is an instance of a computer program that is being executed. It contains the program code and its current activity. Depending on the operating system , a process may be made up of multiple threads of execution that execute instructions concurrently.A computer program is a...
by its controlling terminal when a user wishes to interrupt the process. In source code
Source code
In computer science, source code is text written using the format and syntax of the programming language that it is being written in. Such a language is specially designed to facilitate the work of computer programmers, who specify the actions to be performed by a computer mostly by writing source...
, SIGINT is a symbolic constant
C preprocessor
The C preprocessor is the preprocessor for the C and C++ computer programming languages. The preprocessor handles directives for source file inclusion , macro definitions , and conditional inclusion ....
defined in the header file
Header file
Some programming languages use header files. These files allow programmers to separate certain elements of a program's source code into reusable files. Header files commonly contain forward declarations of classes, subroutines, variables, and other identifiers...
signal.hSignal.hsignal.h is a header file defined in the C Standard Library to specify how a program handles signals while it executes. A signal can report some exceptional behavior within the program , or a signal can report some asynchronous event outside the program .A signal can be generated...
. Symbolic signal names are used because a signal's numeric value can vary across platforms; on the vast majority of systems, it is signal #2Etymology
SIG is a common prefix for signal names. INT is an abbreviated form of interrupt.Usage
SIGINT is sent when the user on the process' controlling terminalComputer terminal
A computer terminal is an electronic or electromechanical hardware device that is used for entering data into, and displaying data from, a computer or a computing system...
presses the interrupt the running process key — typically Control-C, but on some systems, the "delete
Delete key
The delete key , known less ambiguously as forward delete, performs a function when struck on a computer keyboard during text or command editing, which is to discard the character ahead of the cursor's position, moving all following characters one position "back" towards the freed letterspace. The...
" character or "break
Break key
The origins of the break key on a computer keyboard go back to telegraph practices. A standard telegraph key has a built-in knife switch that can be used to short the key's contacts. When the key was not in use, that switch was kept closed, so that a signal was continually sent...
" key.