Changed some exceptions types.