Because in line 7 you assign to p a pointer to the string "hello", loosing the path to the allocated memory (a memory leak).
Use the strcpy function to assign to the memory pointed by p instead of p itself.(strcpy(p,"hello");)
No output when working with pointers usually means crash. And it is indeed a crash.
Incompatible pointer assignment is happening here. The type of "hello" is const char , this is a statically allocated string by the compiler.
The type of p is char*, thus invalid pointer is being passed to the free function, causing the crash.