280 XDR *xdrs = &xdr_stream;
286 u_int maxbufsize = 0;
291 char *uaddrp = uaddress;
315 size_t outlen_pmap = 0;
318 char *outbuf_pmap =
NULL;
324 if (sys_auth ==
NULL) {
335 nettype =
"datagram_n";
351 if (__rpc_getbroadifs(si.si_af, si.si_proto, si.si_socktype,
352 &fdlist[fdlistno].nal) == 0)
355 fd =
socket(si.si_af, si.si_socktype, si.si_proto);
360 fdlist[fdlistno].af = si.si_af;
361 fdlist[fdlistno].proto = si.si_proto;
362 fdlist[fdlistno].fd =
fd;
363 fdlist[fdlistno].nconf = nconf;
367 pfd[fdlistno].fd = fdlist[fdlistno].fd =
fd;
371 if (maxbufsize <= fdlist[fdlistno].dsize)
372 maxbufsize = fdlist[fdlistno].dsize;
376 udpbufsz = fdlist[fdlistno].dsize;
377 if ((outbuf_pmap =
malloc(udpbufsz)) ==
NULL) {
393 if (maxbufsize == 0) {
399 outbuf =
malloc(maxbufsize);
416 barg.args.args_val = argsp;
417 barg.xdr_args = xargs;
419 bres.results.results_val = resultsp;
420 bres.xdr_res = xresults;
440 barg_pmap.prog =
prog;
441 barg_pmap.vers = vers;
442 barg_pmap.proc =
proc;
443 barg_pmap.args_ptr = argsp;
444 barg_pmap.xdr_args = xargs;
445 bres_pmap.port_ptr = &
port;
446 bres_pmap.xdr_results = xresults;
447 bres_pmap.results_ptr = resultsp;
466 for (msec = inittime; msec <= waittime; msec += msec) {
470 for (
i = 0;
i < fdlistno;
i++) {
471 if (fdlist[
i].dsize < outlen) {
491 (
size_t)fdlist[
i].asize) !=
496 warnx(
"clnt_bcast: cannot send" 515 outlen_pmap, 0,
addr,
516 (
size_t)fdlist[
i].asize) !=
519 "Cannot send broadcast packet");
534 if (eachresult ==
NULL) {
544 switch (pollretval =
poll(
pfd, fdlistno, msec)) {
552 for (
i = fds_found = 0;
553 i < fdlistno && fds_found < pollretval;
i++) {
556 if (
pfd[
i].revents == 0)
577 0, (
struct sockaddr *)(
void *)&fdlist[
i].raddr,
582 warnx(
"clnt_bcast: Cannot receive reply to " 598 msg.acpted_rply.ar_results.where =
600 msg.acpted_rply.ar_results.proc =
603 }
else if (pmap_flag &&
608 msg.acpted_rply.ar_results.where =
610 msg.acpted_rply.ar_results.proc =
624 if (pmap_flag && pmap_reply_flag) {
628 taddr.len = taddr.maxlen =
629 sizeof(fdlist[
i].raddr);
630 taddr.buf = &fdlist[
i].raddr;
631 done = (*eachresult)(resultsp,
632 &taddr, fdlist[
i].nconf);
640 fdlist[
i].nconf, uaddrp);
641 done = (*eachresult)(resultsp,
642 np, fdlist[
i].nconf);
655 (
void) (*xresults)(xdrs, resultsp);
675 for (
i = 0;
i < fdlistno;
i++) {
u_int __rpc_get_t_size(int af, int proto, int size)
INT WSAAPI recvfrom(IN SOCKET s, OUT CHAR FAR *buf, IN INT len, IN INT flags, OUT LPSOCKADDR from, IN OUT INT FAR *fromlen)
struct sockaddr_storage broadaddr
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
SOCKET WSAAPI socket(IN INT af, IN INT type, IN INT protocol)
int __rpc_broadenable(int af, int s, struct broadif *bip)
struct netconfig * __rpc_getconf(void *vhandle)
#define TAILQ_FIRST(head)
#define xdr_destroy(xdrs)
bool_t xdr_rmtcallres(XDR *xdrs, struct rmtcallres *crp)
AUTH * authunix_create_default()
#define gettimeofday(tv, tz)
bool_t(* xdrproc_t)(XDR *,...)
namespace GUID const ADDRINFOEXW ADDRINFOEXW struct timeval OVERLAPPED LPLOOKUPSERVICE_COMPLETION_ROUTINE HANDLE * handle
struct opaque_auth _null_auth
void __rpc_freebroadifs(broadlist_t *list)
_CRTIMP void __cdecl perror(_In_opt_z_ const char *_ErrMsg)
_Check_return_opt_ _CRTIMP int __cdecl fprintf(_Inout_ FILE *_File, _In_z_ _Printf_format_string_ const char *_Format,...)
struct netbuf * uaddr2taddr(const struct netconfig *nconf, const char *uaddr)
bool_t xdr_rmtcall_args(XDR *xdrs, struct rmtcallargs *cap)
bool_t xdr_callmsg(XDR *xdrs, struct rpc_msg *cmsg)
bool_t xdr_rpcb_rmtcallres(XDR *xdrs, struct rpcb_rmtcallres *p)
struct opaque_auth ah_verf
int poll(struct pollfd *ufds, int nfds, int timeout)
bool_t xdr_rpcb_rmtcallargs(XDR *xdrs, struct rpcb_rmtcallargs *p)
static PIXELFORMATDESCRIPTOR pfd
GLenum const GLvoid * addr
#define memcpy(s1, s2, n)
#define TAILQ_NEXT(elm, field)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
void * __rpc_setconf(char *nettype) const
#define __RPC_GETXID(now)
void xdrmem_create(XDR *xdrs, char *addr, u_int size, enum xdr_op op)
INT WSAAPI sendto(IN SOCKET s, IN CONST CHAR FAR *buf, IN INT len, IN INT flags, IN CONST struct sockaddr *to, IN INT tolen)
struct opaque_auth ah_cred
void __rpc_endconf(void *vhandle)
int __rpc_nconf2sockinfo(const struct netconfig *nconf, struct __rpc_sockinfo *sip)
unsigned long nc_semantics
#define AUTH_DESTROY(auth)
_STLP_DECLSPEC complex< float > _STLP_CALL sin(const complex< float > &)
bool_t xdr_replymsg(XDR *xdrs, struct rpc_msg *rmsg)
__BEGIN_DECLS u_int __rpc_get_a_size(int)
#define XDR_DESTROY(xdrs)