boom: Segfault Test Function boom

Description Usage Value

Description

test function produces a C++ segfault. Calls function baz which allocates a wrong pointer. If you compiled this code with CXXFLAGS=-g3 -rdynamic the installed function handler will print a traceback of the stack that contains the name of the offending function. Without this compiler flag, you miss the function name. you should place a call to signal(SIGSEGV, handler); at the beginning of each function you want to check for segfaults.

Usage

1
  boom()

Value

R will crash with a segfault but you will see a traceback. ONLY run in console.


floswald/umod documentation built on May 16, 2019, 1:24 p.m.