https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112442
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> --- Looks like it doesn't always segfault, but the contents of the tmp buffer are incorrect (which might segfault, or might fail to print "test!").