Fix exception when protocol is not supported