git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@3105 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1997-08-24 06:10:51 +00:00
parent fea121490f
commit b8883bb0fc

View File

@@ -80,12 +80,21 @@ init_socket(struct descr *d, int type, int port)
static int
init_sockets(struct descr **d)
{
*d = malloc(4 * sizeof(**d));
int nsockets = 4;
#ifdef KASERVER
nsockets++;
#endif
*d = malloc(nsockets * sizeof(**d));
init_socket(*d + 0, SOCK_DGRAM, 88);
init_socket(*d + 1, SOCK_DGRAM, 750);
init_socket(*d + 2, SOCK_STREAM, 88);
init_socket(*d + 3, SOCK_STREAM, 750);
return 4;
#ifdef KASERVER
init_socket(*d + 4, SOCK_DGRAM, 7004);
#endif
return nsockets;
}
@@ -122,6 +131,12 @@ process_request(unsigned char *buf,
return ret;
}
#endif
#ifdef KASERVER
else {
ret = do_kaserver (buf, len, reply, from, (struct sockaddr_in*)addr);
return ret;
}
#endif
return -1;
}