I'm surprised that even compiles. scanf only takes pointers... you are giving it a char instead of a pointer to a char.
Edit : To little sleep, not enough reading before posting... myString is an array and therefore equivalent to a pointer
Also, I am reasonably sure that you need to make the array one char larger to allow for the NULL terminator.
Last edited by urzumph; 07-15-2006 at 04:02 PM.
|