Path: utzoo!mnetor!uunet!husc6!mailrus!ames!pasteur!ucbvax!TWG.COM!mja From: mja@TWG.COM (Mike Anello) Newsgroups: comp.protocols.tcp-ip Subject: RE: (TLI HELP) Message-ID: <8803241129.AA04922@ucbvax.Berkeley.EDU> Date: 23 Mar 88 20:04:00 GMT Sender: uucp@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 19 In reply to Gil Widdowson note about TLI HELP: In both socket and tli calls sockaddr_in structure is used to specify an internet address. Since sin_zero element of this structure does not contain any usefull data, only the first three elements (the first 8 bytes) should be passed to buffers used in tli calls. Two constants UDP_BINDADDRLEN in udp.h and TCP_BINDADDRLEN in tcp.h may be used for this purpose. When using t_bind(fd, req, ret) call, you will get back in ret.addr.buf the address assigned by the transport provider. This address is 8 bytes long and represents the first three elements of sockaddr_in structure. In t_bind(fd, NULL, &ret) call, transport provider will assign INADDR_ANY address, and the next available port number to the end point. Mohsen Mortazavi The Wollongong Group