bind() arguments

Marina Arseniev marina at osiris.UUCP
Fri Feb 15 08:32:42 AEST 1985


How is the bind() call in 4.2BSD TCP/IP supposed to be used.
In the bind call, what is the namelen parameter and in the sockaddr
structure, how is sa_data used.  My code looks like:

main()
{
	struct  sockaddr LAB, *LABp;

	s = socket( AF_INET, SOCK_STREAM, 0 );
	LAB.sa_family = AF_INET;
	strcpy( LAB.sa_data, "128.000.00.0");
	LABp = &LAB;
	bind( s, LABp, <namelen>);

}

Please respond by mail.  Thank you very much.



-- 

					marina
					...!seismo!umcp-cs!aplvax!osiris!marina



More information about the Comp.unix.wizards mailing list