minor cleanups

This commit is contained in:
cebix 2005-06-30 21:25:26 +00:00
parent ec8661f431
commit fa5ae3ab6e
7 changed files with 17 additions and 14 deletions

View File

@ -4,7 +4,7 @@ dnl Additional macros for Basilisk II
dnl Check for libgnomeui
dnl B2_PATH_GNOMEUI([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
dnl Test to see if libgnomeui is installed, and define GNOMEUI_CFLAGS, LIBS
AC_DEFUN(B2_PATH_GNOMEUI,
AC_DEFUN([B2_PATH_GNOMEUI],
[dnl
dnl Get the cflags and libraries from the gnome-config script
dnl

View File

@ -309,7 +309,7 @@ AC_SYS_LARGEFILE
dnl Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS(unistd.h fcntl.h sys/types.h sys/time.h sys/mman.h mach/mach.h)
AC_CHECK_HEADERS(unistd.h stdlib.h fcntl.h sys/types.h sys/time.h sys/mman.h mach/mach.h)
AC_CHECK_HEADERS(readline.h history.h readline/readline.h readline/history.h)
AC_CHECK_HEADERS(sys/socket.h sys/ioctl.h sys/filio.h sys/bitypes.h sys/wait.h)
AC_CHECK_HEADERS(sys/poll.h sys/select.h)
@ -421,7 +421,7 @@ dnl (end of code from openssh-3.2.2p1 configure.ac)
dnl AC_CHECK_FRAMEWORK($1=NAME, $2=INCLUDES)
AC_DEFUN(AC_CHECK_FRAMEWORK, [
AC_DEFUN([AC_CHECK_FRAMEWORK], [
AS_VAR_PUSHDEF([ac_Framework], [ac_cv_framework_$1])dnl
AC_CACHE_CHECK([whether compiler supports framework $1],
ac_Framework, [
@ -585,7 +585,7 @@ dnl to be put into the config.h file
dnl $1 -- the macro to define
dnl $2 -- the value to translate
dnl $3 -- template name
AC_DEFUN(AC_TRANSLATE_DEFINE, [
AC_DEFUN([AC_TRANSLATE_DEFINE], [
if [[ "x$2" = "xyes" -o "x$2" = "xguessing yes" ]]; then
AC_DEFINE($1, 1, $3)
fi

View File

@ -310,7 +310,7 @@ fork_exec(so, ex, do_pty)
{
int s;
struct sockaddr_in addr;
int addrlen = sizeof(addr);
socklen_t addrlen = sizeof(addr);
int opt;
int master;
char *argv[256];

View File

@ -385,7 +385,7 @@ sorecvfrom(so)
struct socket *so;
{
struct sockaddr_in addr;
int addrlen = sizeof(struct sockaddr_in);
socklen_t addrlen = sizeof(struct sockaddr_in);
DEBUG_CALL("sorecvfrom");
DEBUG_ARG("so = %lx", (long)so);
@ -538,7 +538,9 @@ solisten(port, laddr, lport, flags)
{
struct sockaddr_in addr;
struct socket *so;
int s, addrlen = sizeof(addr), opt = 1;
int s;
socklen_t addrlen = sizeof(addr);
int opt = 1;
DEBUG_CALL("solisten");
DEBUG_ARG("port = %d", port);

View File

@ -460,7 +460,7 @@ tcp_connect(inso)
{
struct socket *so;
struct sockaddr_in addr;
int addrlen = sizeof(struct sockaddr_in);
socklen_t addrlen = sizeof(struct sockaddr_in);
struct tcpcb *tp;
int s, opt;
@ -655,7 +655,7 @@ tcp_emu(so, m)
{
struct socket *tmpso;
struct sockaddr_in addr;
int addrlen = sizeof(struct sockaddr_in);
socklen_t addrlen = sizeof(struct sockaddr_in);
struct sbuf *so_rcv = &so->so_rcv;
memcpy(so_rcv->sb_wptr, m->m_data, m->m_len);

View File

@ -26,7 +26,7 @@
struct tftp_session {
int in_use;
unsigned char filename[TFTP_FILENAME_MAX];
char filename[TFTP_FILENAME_MAX];
struct in_addr client_ip;
u_int16_t client_port;
@ -239,7 +239,7 @@ static void tftp_handle_rrq(struct tftp_t *tp, int pktlen)
spt = &tftp_sessions[s];
src = tp->x.tp_buf;
dst = spt->filename;
dst = (u_int8_t *)spt->filename;
n = pktlen - ((uint8_t *)&tp->x.tp_buf[0] - (uint8_t *)tp);
/* get name */
@ -292,7 +292,7 @@ static void tftp_handle_rrq(struct tftp_t *tp, int pktlen)
/* check if the file exists */
if (tftp_read_data(spt, 0, spt->filename, 0) < 0) {
if (tftp_read_data(spt, 0, (u_int8_t *)spt->filename, 0) < 0) {
tftp_send_error(spt, 1, "File not found", tp);
return;
}

View File

@ -402,7 +402,7 @@ udp_emu(so, m)
struct mbuf *m;
{
struct sockaddr_in addr;
int addrlen = sizeof(addr);
socklen_t addrlen = sizeof(addr);
#ifdef EMULATE_TALK
CTL_MSG_OLD *omsg;
CTL_MSG *nmsg;
@ -633,7 +633,8 @@ udp_listen(port, laddr, lport, flags)
{
struct sockaddr_in addr;
struct socket *so;
int addrlen = sizeof(struct sockaddr_in), opt = 1;
socklen_t addrlen = sizeof(struct sockaddr_in);
int opt = 1;
if ((so = socreate()) == NULL) {
free(so);