출처 http://c-faq.com Q: I'm trying to declare a pointer and allocate some space for it, but it's not working. What's wrong with this code? char *p; *p = malloc(10); => 언뜻 보기에는 될것 같이 생겼다.. A: The pointer you declared is p, not *p. When you're manipulating the pointer itself (for example when you're setting it to make it point somewhere), you just use the name of the pointer: p = malloc(10); It's w..