Memory allocation validation

malloc is used to allocate the state structure, but XXHxx_resetState() uses the allocated buffer without checking if allocation was successful.
User can then check for NULL pointer to validate that XXHxx_init was successful without a core dump.

thank you.
Merge pull request #4 from sfgagnon/patch-1

Memory allocation validation