use krb5_socket_t

This commit is contained in:
Love Hornquist Astrand
2009-12-23 14:12:38 +01:00
parent 160ddd0e43
commit be73fa4687
5 changed files with 12 additions and 12 deletions

View File

@@ -124,7 +124,7 @@ spawn_child(krb5_context context, int *socks,
struct sockaddr_storage __ss;
struct sockaddr *sa = (struct sockaddr *)&__ss;
socklen_t sa_size = sizeof(__ss);
SOCKET s;
krb5_socket_t s;
pid_t pid;
krb5_address addr;
char buf[128];
@@ -165,7 +165,7 @@ spawn_child(krb5_context context, int *socks,
static int
wait_for_connection(krb5_context context,
SOCKET *socks, unsigned int num_socks)
krb5_socket_t *socks, unsigned int num_socks)
{
unsigned int i;
int e;
@@ -226,7 +226,7 @@ start_server(krb5_context context)
int e;
struct kadm_port *p;
SOCKET *socks = NULL, *tmp;
krb5_socket_t *socks = NULL, *tmp;
unsigned int num_socks = 0;
int i;
@@ -259,7 +259,7 @@ start_server(krb5_context context)
}
socks = tmp;
for(ap = ai; ap; ap = ap->ai_next) {
SOCKET s = socket(ap->ai_family, ap->ai_socktype, ap->ai_protocol);
krb5_socket_t s = socket(ap->ai_family, ap->ai_socktype, ap->ai_protocol);
if(rk_IS_BAD_SOCKET(s)) {
krb5_warn(context, rk_SOCK_ERRNO, "socket");
continue;

View File

@@ -95,7 +95,7 @@ main(int argc, char **argv)
int i;
krb5_log_facility *logfacility;
krb5_keytab keytab;
SOCKET sfd = INVALID_SOCKET;
krb5_socket_t sfd = rk_INVALID_SOCKET;
setprogname(argv[0]);

View File

@@ -1091,7 +1091,7 @@ process_stream(krb5_context context,
int
handle_mit(krb5_context context, void *buf, size_t len, SOCKET sock)
handle_mit(krb5_context context, void *buf, size_t len, krb5_socket_t sock)
{
krb5_storage *sp;

View File

@@ -440,7 +440,7 @@ v5_loop (krb5_context context,
krb5_auth_context ac,
krb5_boolean initial,
void *kadm_handle,
SOCKET fd)
krb5_socket_t fd)
{
krb5_error_code ret;
krb5_data in, out;
@@ -476,7 +476,7 @@ match_appl_version(const void *data, const char *appl_version)
static void
handle_v5(krb5_context context,
krb5_keytab keytab,
SOCKET fd)
krb5_socket_t fd)
{
krb5_error_code ret;
krb5_ticket *ticket;
@@ -539,7 +539,7 @@ handle_v5(krb5_context context,
krb5_error_code
kadmind_loop(krb5_context context,
krb5_keytab keytab,
SOCKET sock)
krb5_socket_t sock)
{
u_char buf[sizeof(KRB5_SENDAUTH_VERSION) + 4];
ssize_t n;

View File

@@ -82,7 +82,7 @@ get_connected_socket(rk_socket_t * s_ret)
goto done;
*s_ret = s;
s = INVALID_SOCKET;
s = rk_INVALID_SOCKET;
rv = 0;
done:
@@ -105,7 +105,7 @@ const char * test_strings[] = {
static int
test_simple_echo_client(void)
{
rk_socket_t s = INVALID_SOCKET;
rk_socket_t s = rk_INVALID_SOCKET;
int rv;
char buf[81];
int i;
@@ -165,7 +165,7 @@ test_simple_echo_socket(void)
return test_simple_echo_client();
} else {
rk_socket_t s = INVALID_SOCKET;
rk_socket_t s = rk_INVALID_SOCKET;
fprintf (stderr, "[%s] Listening for connections...\n", prog);
mini_inetd(htons(PORT), &s);