}
} else if (p.cb instanceof ZooKeeperSaslClient.ServerSaslResponseCallback) {
ZooKeeperSaslClient.ServerSaslResponseCallback cb = (ZooKeeperSaslClient.ServerSaslResponseCallback) p.cb;
SetSASLResponse rsp = (SetSASLResponse) p.response;
// TODO : check rc (== 0, etc) as with other packet types.
cb.processResult(rc,null,p.ctx,rsp.getToken(),null);
ClientCnxn clientCnxn = (ClientCnxn)p.ctx;
if ((clientCnxn == null) || (clientCnxn.zooKeeperSaslClient == null) ||
(clientCnxn.zooKeeperSaslClient.getSaslState() == ZooKeeperSaslClient.SaslState.FAILED)) {
queueEvent(new WatchedEvent(EventType.None,
KeeperState.AuthFailed, null));