Trying to change weapons while cursed (that is, not switch weapons, but change what is equipped) generates the "An unexpected error has occurred on the server." message in the chat log.