==127213== Memcheck, a memory error detector ==127213== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al. ==127213== Using Valgrind-3.15.0 and LibVEX; rerun with -h for copyright info ==127213== Command: ./segmentation_fault.null ==127213== ==127213== Invalid read of size 1 ==127213== at 0x4006C2: print_string (segmentation_fault.null.c:11) ==127213== by 0x40070D: main (segmentation_fault.null.c:20) ==127213== Address 0x0 is not stack'd, malloc'd or (recently) free'd ==127213== ==127213== ==127213== Process terminating with default action of signal 11 (SIGSEGV) ==127213== Access not within mapped region at address 0x0 ==127213== at 0x4006C2: print_string (segmentation_fault.null.c:11) ==127213== by 0x40070D: main (segmentation_fault.null.c:20) ==127213== If you believe this happened as a result of a stack ==127213== overflow in your program's main thread (unlikely but ==127213== possible), you can try to increase the size of the ==127213== main thread stack using the --main-stacksize= flag. ==127213== The main thread stack size used in this run was 8388608. ==127213== ==127213== HEAP SUMMARY: ==127213== in use at exit: 0 bytes in 0 blocks ==127213== total heap usage: 1 allocs, 1 frees, 4 bytes allocated ==127213== ==127213== All heap blocks were freed -- no leaks are possible ==127213== ==127213== For lists of detected and suppressed errors, rerun with: -s ==127213== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) ./_make_valgrind_txt.sh: line 3: 127213 Segmentation fault (core dumped) valgrind --leak-check=full --track-origins=yes "${@}"