SIGSEGV

SIGSEGV

Infobox Computing signal
description = Invalid memory reference
action = Abnormal termination of the process
SEGV_MAPERR | Address not mapped to object
SEGV_ACCERR | Invalid permissions for mapped object
On POSIX-compliant platforms, SIGSEGV is the signal thrown by computer programs making invalid memory references, or segmentation faults. The symbolic constant for SIGSEGV is defined in the header file signal.h. Symbolic signal names are used because signal numbers can vary across platforms; in practice it is usually signal #11.

Etymology

"SIG" is a common prefix for signal names. "SEGV" is an abbreviation of "segmentation violation".

Usage

Computer programs may throw SIGSEGV for improper memory handling (see segmentation fault). The operating system may inform the application of the nature of the error using the signal stack, which developers can use to debug their programs or handle errors.

The default action for a program upon receiving SIGSEGV is abnormal termination. This action will end the process, but may generate a core file to aid debugging, or perform some other platform-dependent action. For example, Linux systems using the grsecurity patch may log SIGSEGV signals in order to monitor for possible intrusion attempts using buffer overflows.

SIGSEGV can be caught; that is, applications can request what action they want to occur in place of the default. Examples of such action might be ignoring it, calling a function, or restoring the default action. In some circumstances, ignoring SIGSEGV results in undefined behavior. [http://www.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_04.html] .

An example of an application that might handle SIGSEGV is a debugger, which might check the signal stack and inform the developer of what happened, and where the program terminated.

SIGSEGV is usually generated by the operating system, but users with appropriate permissions can use the kill system call or kill command (a userland program, or sometimes a shell builtin) to send the signal to a process at will.


Wikimedia Foundation. 2010.

Игры ⚽ Нужно решить контрольную?

Look at other dictionaries:

  • SIGSEGV — Описание: Исключение при обращении в память По умолчанию: завершение с дампом памяти коды SA SIGINFO SEGV MAPERR Обращение к незадействованной странице SEGV ACCERR Нарушение прав доступа к странице В POSIX системах, SIGSEGV  сигнал,… …   Википедия

  • SIGSEGV — Bei Computern tritt eine Schutzverletzung (v. engl. segmentation fault oder segmentation violation, kurz auch segfault) auf, wenn ein Computerprogramm auf eine Ressource (insbesondere auf Speicher) zuzugreifen versucht, die vor einem solchen… …   Deutsch Wikipedia

  • SIGSEGV — En informatique, SIGSEGV est un signal sur les systèmes de type UNIX, et Linux en particulier. Il signifie « signal de violation de segmentation » (Signal Segmentation Violation). C est un signal envoyé à un processus lorsque celui ci… …   Wikipédia en Français

  • SIGSEGV — Segmentation Violation Signal (Signal Nr. 11) unter X/Open UNIX erzeugt normalerweise ein Core Dump ( >xedit /usr/include/signal.h) …   Acronyms

  • SIGSEGV — Segmentation Violation Signal (Signal Nr. 11) unter X/Open UNIX erzeugt normalerweise ein Core Dump ( >xedit /usr/include/signal.h) …   Acronyms von A bis Z

  • 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 …   Wikipedia

  • signal.h — Стандартная библиотека языка программирования С assert.h complex.h ctype.h errno.h fenv.h float.h inttypes.h iso646.h limits.h locale.h math.h setjmp.h signal.h stdarg.h stdbool.h stddef.h …   Википедия

  • Segmentation fault — A segmentation fault (often shortened to segfault) is a particular error condition that can occur during the operation of computer software. A segmentation fault occurs when a program attempts to access a memory location that it is not allowed to …   Wikipedia

  • Ошибка сегментации — (англ. Segmentation fault или сокращённо segfault)  ошибка программного обеспечения, возникающая при попытке обращения к недоступным для записи участкам памяти либо при попытке изменения памяти запрещённым способом. В системах на основе …   Википедия

  • Cyclone (programming language) — Cyclone Appeared in 2006 (2006) Designed by AT T Labs Stable release 1.0 (May 8, 2006; 5 years ago (2006 05 08)) Influenced by …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”