/* To reproduce : # gcc -O0 -pipe -ggdb3 gdb-crash.c -o gdb-crash # gdb gdb-crash (gdb) break gdb-crash.c:14 (gdb) run (gdb) set tp = {0,0} *crash* */ #include struct test { int a; int b; }; int main() { struct test tv = { 1, 1 }; struct test *tp = &tv; printf("Test is %u, %u\n", tv.a, tv.b); return 0; }