renamed capwap directory to cw.
FossilOrigin-Name: 8a43dd9d05a4cb73210243ddd8df2a26f16c7ef2c4d4e36ab446de1f65d88223
This commit is contained in:
22
src/cw/sock_addrinit.c
Normal file
22
src/cw/sock_addrinit.c
Normal file
@ -0,0 +1,22 @@
|
||||
#include <string.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netinet/in.h>
|
||||
|
||||
void sock_addrinit(struct sockaddr *addr,int type)
|
||||
{
|
||||
switch (type){
|
||||
case AF_INET:
|
||||
memset(addr,0,sizeof(struct sockaddr_in));
|
||||
addr->sa_family=type;
|
||||
#ifdef HAVE_SIN_LEN
|
||||
addr_sa_len=sizeof(struct sockaddr_in);
|
||||
#endif
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
Reference in New Issue
Block a user