//---------------------------------------------------------------- // signal1.cpp // // This program will attempt to dereference a null pointer, // to see how the system would respond to this illegal act. // // compile-and-link using: $ g++ signal1.cpp -o signal1 // // programmer: ALLAN CRUSE // written on: 20 MAR 2006 //---------------------------------------------------------------- #include // for printf() int main( int argc, char *argv[] ) { int *ptr = NULL; int x = *ptr; printf( "\nx = %08X \n\n", x ); }