Check for valid m_notify_state_change_fn during shutdown to avoid crash in case that this callback has not been set.
Check for valid m_notify_state_change_fn during shutdown to avoid crash in case that this callback has not been set.

darrenjs/wampcc,darrenjs/wampcc,darrenjs/wampcc,darrenjs/wampcc,darrenjs/wampcc