Segmentation Fault - Bug Reaper

                  Bug Reaper

Lean about Automation Testing,Selenium WebDriver,RestAssured,Appium,Jenkins,JAVA,API Automation,TestNG,Maven, Rest API, SOAP API,Linux,Maven,Security Testing,Interview Questions

Monday, 23 September 2013

Segmentation Fault



Segmentation Fault:An error in which a running program attempts to access memory not allocated to it and core dumps with a segmentation violation error. This is often caused by improper usage of pointers in the source code.

It is one of the most common problems when making software is errors like “Segmentation fault“, also called SegFault. 


Concept behind Segmentation Fault:
Virtual memory in a computer can be created in 2 ways: pages or segments. Paging means that the memory is divided in pages of equal size, containing words of memory in it. Segmentation means that every process has a segment of memory of needed size, with gaps of empty memory blocks between the segments.

The operating system knows the upper limit of every segment, and every segment begins at a virtual address. When a program accesses a memory block, it calls a virtual address that the Memory Management Unit (MMU) maps to a real address. If the operating system sees that the requested address doesn’t match any valid address in the segment, it will send a signal to the process terminating it. SegFaults are the direct result of a memory error.
 

No comments:

Post a Comment