public void handleReply(Packet packet) {
        timeoutTask.kill();
        if (packet == null) {
            req.setError(ErrorCode.BAD_REPLY, "Bad reply packet");
        } else {
            int pcode = packet.packetCode();
            if (pcode == Packet.PCODE_REPLY) {
                ReplyPacket rp = (ReplyPacket) packet;
                req.returnValues(rp.returnValues());
            } else if (pcode == Packet.PCODE_ERROR) {
                ErrorPacket ep = (ErrorPacket) packet;
                req.setError(ep.errorCode(), ep.errorMessage());
            }
        }
        reqWaiter.handleRequestDone(req);
    }
Handle normal packet reply. The reply may contain either return
values or an error.
jrt/src/com/yahoo/jrt/InvocationClient.java