Added error handling for /ping command responses
Merge branch 'master' into xep-0223