My if is not checking if pointer is initialized. What am i doing wrong ? In Wt hangman tutorial files they have done it this way and for them it works.
It's not possible to check if a pointer has been initialized, only if it equal or not to zero, which is what you're doing. If you don't actually initialize it to zero, the value is undefined (probably non-zero).