/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
#define _XPG4_2
#define __EXTENSIONS__
#include <assert.h>
#include <sys/socketvar.h>
#include <errno.h>
#include <stdlib.h>
#include <unistd.h>
#include <stropts.h>
#include <stdio.h>
#include <strings.h>
/* This will hold either a v4 or a v6 sockaddr */
union sockaddr_storage_v6 {
};
/*
* This file implements all the libsctp calls.
*/
/*
* To bind a list of addresses to a socket. If the socket is
* v4, the type of the list of addresses is (struct in_addr).
* If the socket is v6, the type is (struct in6_addr).
*/
int
{
return (-1);
}
/* Assume the caller uses the correct family type. */
case AF_INET:
sz = sizeof (struct sockaddr_in);
break;
case AF_INET6:
sz = sizeof (struct sockaddr_in6);
break;
default:
return (-1);
}
switch (flags) {
case SCTP_BINDX_ADD_ADDR:
case SCTP_BINDX_REM_ADDR:
default:
return (-1);
}
}
/*
* XXX currently not atomic -- need a better way to do this.
*/
int
{
return (-1);
}
/* First, find out how many peer addresses there are. */
return (-1);
}
if (naddrs == 0)
return (0);
/*
* Now we can get all the peer addresses. This will over allocate
* space for v4 socket. But it should be OK and save us
* the job to find out if it is a v4 or v6 socket.
*/
return (-1);
}
return (-1);
}
/* Calculate the number of addresses returned. */
case AF_INET:
break;
case AF_INET6:
break;
}
return (naddrs);
}
void
{
}
int
{
return (-1);
}
/* First, try to find out how many bound addresses there are. */
return (-1);
}
if (naddrs == 0)
return (0);
/*
* Now we can get all the bound addresses. This will over allocate
* space for v4 socket. But it should be OK and save us
* the job to find out if it is a v4 or v6 socket.
*/
return (-1);
}
return (-1);
}
/* Calculate the number of addresses returned. */
case AF_INET:
break;
case AF_INET6:
break;
}
return (naddrs);
}
void
{
}
int
{
return (-1);
}
return (0);
}
/*
* Branch off an association to its own socket. ioctl() allocates and
* returns new fd.
*/
int
{
int fd;
return (-1);
}
return (fd);
}
{
int err;
} else {
hdr.msg_controllen = 0;
}
if (err == -1) {
return (-1);
}
}
}
break;
}
}
}
return (err);
}
static ssize_t
{
sinfo->sinfo_cumtsn = 0;
}
{
/* Note that msg can be NULL for pure control message. */
return (-1);
}
}
{
}