Lines Matching defs:xdr
28 xdr_s_type *xdr;
61 extern void xdr_destroy_common(xdr_s_type *xdr);
62 extern bool_t xdr_recv_reply_header (xdr_s_type *xdr, rpc_reply_header *reply);
78 (client->xdr->x_prog | 0x01000000),
79 client->xdr->x_vers);
91 (client->xdr->x_prog | 0x01000000),
92 client->xdr->x_vers);
103 ntohl(((uint32 *)(client->xdr->in_msg))[RPC_OFFSET+3]);
105 ntohl(((uint32 *)(client->xdr->in_msg))[RPC_OFFSET+4]);
109 XDR **svc_xdr = (XDR **)svc;
110 D("%08x:%08x dispatching RPC call (XID %d, xdr %p) for "
112 client->xdr->x_prog,
113 client->xdr->x_vers,
114 ntohl(((uint32 *)(client->xdr->in_msg))[RPC_OFFSET]),
115 client->xdr,
117 /* We transplant the xdr of the client into the entry
126 D("%08x:%08x expecting XDR == NULL"
128 client->xdr->x_prog,
129 client->xdr->x_vers,
134 D("%08x:%08x cloning XDR for "
136 client->xdr->x_prog,
137 client->xdr->x_vers,
139 *svc_xdr = xdr_clone(client->xdr);
144 client->xdr->in_msg, client->xdr->in_len);
146 client->xdr->out_msg, client->xdr->out_next);
147 (*svc_xdr)->in_len = client->xdr->in_len;
148 (*svc_xdr)->out_next = client->xdr->out_next;
152 client->xdr->x_prog, client->xdr->x_vers);
163 client->xdr->x_prog,
164 client->xdr->x_vers,
169 client->xdr->x_prog,
170 client->xdr->x_vers);
178 (client->xdr->x_prog | 0x01000000),
179 client->xdr->x_vers);
203 if (FD_ISSET(client->xdr->fd, &rfds)) {
205 /* We need to make sure that the XDR's in_buf is not in
214 D("%08x:%08x waiting for XDR input buffer "
216 client->xdr->x_prog, client->xdr->x_vers);
222 client->xdr->x_prog, client->xdr->x_vers);
224 client->xdr->xops->read(client->xdr);
228 if (((uint32 *)(client->xdr->in_msg))[RPC_OFFSET+1] ==
233 client->xdr->x_prog,
234 client->xdr->x_vers,
235 ntohl(((uint32 *)client->xdr->in_msg)[RPC_OFFSET]));
238 client->xdr->x_prog,
239 client->xdr->x_vers);
248 client->xdr->x_prog,
249 client->xdr->x_vers);
253 client->xdr->x_prog,
254 client->xdr->x_vers);
261 client->xdr->x_prog,
262 client->xdr->x_vers);
276 if (trav->xdr)
278 trav->xdr->x_prog,
279 trav->xdr->x_vers,
280 trav->xdr->fd);
306 xdr_s_type *xdr = client->xdr;
316 xdr->x_op = XDR_ENCODE;
320 if (!xdr_call_msg_start (xdr, xdr->x_prog, xdr->x_vers,
322 XDR_MSG_ABORT (xdr);
325 client->xdr->x_prog,
326 client->xdr->x_vers);
332 if (!xdr_args (xdr, args_ptr)) {
333 XDR_MSG_ABORT(xdr);
336 client->xdr->x_prog,
337 client->xdr->x_vers);
344 client->xdr->x_prog, client->xdr->x_vers, client->xdr->xid);
345 if (!XDR_MSG_SEND(xdr)) {
352 client->xdr->x_prog, client->xdr->x_vers);
354 D("%08x:%08x received reply.\n", client->xdr->x_prog, client->xdr->x_vers);
356 if (((uint32 *)xdr->out_msg)[RPC_OFFSET] !=
357 ((uint32 *)xdr->in_msg)[RPC_OFFSET]) {
359 client->xdr->x_prog, client->xdr->x_vers,
360 ntohl(((uint32 *)xdr->in_msg)[RPC_OFFSET]),
361 ntohl(((uint32 *)xdr->out_msg)[RPC_OFFSET]));
367 client->xdr->x_prog, client->xdr->x_vers);
368 if (!xdr_recv_reply_header (client->xdr, &reply_header)) {
370 client->xdr->x_prog, client->xdr->x_vers);
380 (uint32_t)client->xdr->x_prog, client->xdr->x_vers);
386 (uint32_t)client->xdr->x_prog, client->xdr->x_vers);
390 xdr->x_op = XDR_DECODE;
392 if (!xdr_results(xdr, rets_ptr) || ! XDR_MSG_DONE(xdr)) {
395 client->xdr->x_prog, client->xdr->x_vers);
400 client->xdr->x_prog, client->xdr->x_vers);
405 client->xdr->x_prog, client->xdr->x_vers);
416 bool_t xdr_recv_auth (xdr_s_type *xdr, opaque_auth *auth)
420 if(!XDR_RECV_INT8(xdr, (int8_t *)&(auth->oa_flavor))) return FALSE;
423 if(!XDR_RECV_INT16(xdr, (int16_t *)&(auth->oa_flavor))) return FALSE;
426 if(!XDR_RECV_INT32(xdr, (int32_t *)&(auth->oa_flavor))) return FALSE;
429 if (!XDR_RECV_UINT (xdr, (unsigned *)&(auth->oa_length))) {
436 if (!XDR_RECV_BYTES (xdr, NULL, auth->oa_length))
446 xdr_recv_accepted_reply_header(xdr_s_type *xdr,
449 if (!xdr_recv_auth(xdr, &accreply->verf)) {
453 if (!XDR_RECV_ENUM(xdr, &accreply->stat)) {
459 if (!XDR_RECV_UINT32(xdr, &accreply->u.versions.low)) {
463 if (!XDR_RECV_UINT32(xdr, &accreply->u.versions.high)) {
484 static bool_t xdr_recv_denied_reply(xdr_s_type *xdr,
487 if (!XDR_RECV_ENUM (xdr, &rejreply->stat))
492 if (!XDR_RECV_UINT32(xdr, &rejreply->u.versions.low))
494 if (!XDR_RECV_UINT32(xdr, &rejreply->u.versions.high))
498 if (!XDR_RECV_ENUM (xdr, &rejreply->u.why))
508 bool_t xdr_recv_reply_header (xdr_s_type *xdr, rpc_reply_header *reply)
510 if (!XDR_RECV_ENUM(xdr, &reply->stat)) {
516 if (!xdr_recv_accepted_reply_header(xdr, &reply->u.ar)) {
521 if (!xdr_recv_denied_reply(xdr, &reply->u.dr)) {
550 client->xdr = xdr_init_common(name, 1 /* client XDR */);
551 if (!client->xdr) {
557 client->xdr->x_prog = prog;
558 client->xdr->x_vers = vers;
566 FD_SET(client->xdr->fd, &rx_fdset);
567 if (max_rxfd < client->xdr->fd)
568 max_rxfd = client->xdr->fd;
596 client->xdr->x_prog,
597 client->xdr->x_vers);
604 client->xdr->x_prog,
605 client->xdr->x_vers);
610 client->xdr->x_prog,
611 client->xdr->x_vers);
621 client->xdr->x_prog,
622 client->xdr->x_vers);
628 FD_CLR(client->xdr->fd, &rx_fdset);
646 xdr_destroy_common(client->xdr);