lots of small fixes

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@331 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1996-03-24 06:57:50 +00:00
parent 6e774b61f7
commit 521dcd469e
8 changed files with 30 additions and 27 deletions

View File

@@ -30,7 +30,6 @@ pop_dropcopy(POP *p, struct passwd *pwp)
char buffer[BUFSIZ]; /* Read buffer */
long offset; /* Old/New boundary */
int nchar; /* Bytes written/read */
struct stat mybuf; /* For lstat() */
/* Create a temporary maildrop into which to copy the updated maildrop */
(void)sprintf(p->temp_drop,POP_DROP,p->user);

View File

@@ -29,7 +29,7 @@ int pop_timeout = POP_TIMEOUT;
jmp_buf env;
static int
static RETSIGTYPE
ring()
{
longjmp(env,1);
@@ -41,8 +41,7 @@ ring()
static char *
tgets(char *str, int size, FILE *fp, int timeout)
{
int ring();
(void) signal(SIGALRM, (void *)ring);
(void) signal(SIGALRM, ring);
alarm(timeout);
if (setjmp(env))
str = NULL;
@@ -63,8 +62,8 @@ main (int argc, char **argv)
state_table * s;
char message[MAXLINELEN];
(void) signal(SIGHUP,(void *)catchSIGHUP);
(void) signal(SIGPIPE,(void *)catchSIGHUP);
(void) signal(SIGHUP, catchSIGHUP);
(void) signal(SIGPIPE,catchSIGHUP);
/* Start things rolling */
pop_init(&p,argc,argv);

20
appl/telnet/configure vendored
View File

@@ -1162,12 +1162,12 @@ tgetent()
EOF
if { (eval echo configure:1164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_funclib_tgetent=${ac_lib:-yes}";break
eval "ac_cv_funclib_tgetent=${ac_lib-yes}";break
fi
rm -f conftest*
done
eval "ac_cv_funclib_tgetent=\${ac_cv_funclib_tgetent:-no}"
eval "ac_cv_funclib_tgetent=\${ac_cv_funclib_tgetent-no}"
LIBS="$ac_save_LIBS"
fi
@@ -1240,12 +1240,12 @@ setupterm()
EOF
if { (eval echo configure:1242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_funclib_setupterm=${ac_lib:-yes}";break
eval "ac_cv_funclib_setupterm=${ac_lib-yes}";break
fi
rm -f conftest*
done
eval "ac_cv_funclib_setupterm=\${ac_cv_funclib_setupterm:-no}"
eval "ac_cv_funclib_setupterm=\${ac_cv_funclib_setupterm-no}"
LIBS="$ac_save_LIBS"
fi
@@ -1318,12 +1318,12 @@ socket()
EOF
if { (eval echo configure:1320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_funclib_socket=${ac_lib:-yes}";break
eval "ac_cv_funclib_socket=${ac_lib-yes}";break
fi
rm -f conftest*
done
eval "ac_cv_funclib_socket=\${ac_cv_funclib_socket:-no}"
eval "ac_cv_funclib_socket=\${ac_cv_funclib_socket-no}"
LIBS="$ac_save_LIBS"
fi
@@ -1396,12 +1396,12 @@ gethostbyname()
EOF
if { (eval echo configure:1398: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_funclib_gethostbyname=${ac_lib:-yes}";break
eval "ac_cv_funclib_gethostbyname=${ac_lib-yes}";break
fi
rm -f conftest*
done
eval "ac_cv_funclib_gethostbyname=\${ac_cv_funclib_gethostbyname:-no}"
eval "ac_cv_funclib_gethostbyname=\${ac_cv_funclib_gethostbyname-no}"
LIBS="$ac_save_LIBS"
fi
@@ -1679,12 +1679,12 @@ logout()
EOF
if { (eval echo configure:1681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_funclib_logout=${ac_lib:-yes}";break
eval "ac_cv_funclib_logout=${ac_lib-yes}";break
fi
rm -f conftest*
done
eval "ac_cv_funclib_logout=\${ac_cv_funclib_logout:-no}"
eval "ac_cv_funclib_logout=\${ac_cv_funclib_logout-no}"
LIBS="$ac_save_LIBS"
fi

View File

@@ -2307,7 +2307,8 @@ int tn(int argc, char **argv)
return 0;
}
#if defined(IP_OPTIONS) && defined(IPPROTO_IP)
if (srp && setsockopt(net, IPPROTO_IP, IP_OPTIONS, (char *)srp, srlen) < 0)
if (srp && setsockopt(net, IPPROTO_IP, IP_OPTIONS, (void *)srp,
srlen) < 0)
perror("setsockopt (IP_OPTIONS)");
#endif
#if defined(IPPROTO_IP) && defined(IP_TOS)
@@ -2321,7 +2322,7 @@ int tn(int argc, char **argv)
tos = 020; /* Low Delay bit */
if (tos
&& (setsockopt(net, IPPROTO_IP, IP_TOS,
(char *)&tos, sizeof(int)) < 0)
(void *)&tos, sizeof(int)) < 0)
&& (errno != ENOPROTOOPT))
perror("telnet: setsockopt (IP_TOS) (ignored)");
}

View File

@@ -92,7 +92,7 @@ SetSockOpt(fd, level, option, yesno)
{
#ifndef NOT43
return setsockopt(fd, level, option,
(char *)&yesno, sizeof yesno);
(void *)&yesno, sizeof yesno);
#else /* NOT43 */
if (yesno == 0) { /* Can't do that in 4.2! */
fprintf(stderr, "Error: attempt to turn off an option 0x%x.\n",

View File

@@ -425,7 +425,7 @@ int main(int argc, char **argv)
exit(1);
}
(void) setsockopt(s, SOL_SOCKET, SO_REUSEADDR,
(char *)&on, sizeof(on));
(void *)&on, sizeof(on));
if (bind(s, (struct sockaddr *)&sin, sizeof sin) < 0) {
perror("bind");
exit(1);
@@ -478,9 +478,9 @@ int main(int argc, char **argv)
*/
#ifdef SO_SEC_MULTI /* 8.0 code */
if ((getsockopt(0, SOL_SOCKET, SO_SECURITY,
(char *)&ss, &szss) < 0) ||
(void *)&ss, &szss) < 0) ||
(getsockopt(0, SOL_SOCKET, SO_SEC_MULTI,
(char *)&sock_multi, &szi) < 0)) {
(void *)&sock_multi, &szi) < 0)) {
perror("getsockopt");
exit(1);
} else {
@@ -498,7 +498,7 @@ int main(int argc, char **argv)
}
#else /* SO_SEC_MULTI */ /* 7.0 code */
if (getsockopt(0, SOL_SOCKET, SO_SECURITY,
(char *)&ss, &szss) >= 0) {
(void *)&ss, &szss) >= 0) {
dv.dv_actlvl = ss.ss_slevel;
dv.dv_actcmp = ss.ss_compart;
dv.dv_minlvl = ss.ss_minlvl;
@@ -518,7 +518,7 @@ int main(int argc, char **argv)
}
if (keepalive &&
setsockopt(0, SOL_SOCKET, SO_KEEPALIVE,
(char *)&on, sizeof (on)) < 0) {
(void *)&on, sizeof (on)) < 0) {
syslog(LOG_WARNING, "setsockopt (SO_KEEPALIVE): %m");
}
@@ -533,7 +533,7 @@ int main(int argc, char **argv)
tos = 020; /* Low Delay bit */
if (tos
&& (setsockopt(0, IPPROTO_IP, IP_TOS,
(char *)&tos, sizeof(tos)) < 0)
(void *)&tos, sizeof(tos)) < 0)
&& (errno != ENOPROTOOPT) )
syslog(LOG_WARNING, "setsockopt (IP_TOS): %m");
}
@@ -1102,7 +1102,7 @@ telnet(f, p, host)
#if defined(SO_OOBINLINE)
(void) setsockopt(net, SOL_SOCKET, SO_OOBINLINE,
(char *)&on, sizeof on);
(void *)&on, sizeof on);
#endif /* defined(SO_OOBINLINE) */
#ifdef SIGTSTP

View File

@@ -14,6 +14,7 @@ RCSID("$Id$");
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <signal.h>
#include <X11/StringDefs.h>
#include <X11/Intrinsic.h>
@@ -26,6 +27,8 @@ RCSID("$Id$");
#include <krb.h>
#include <kafs.h>
char *crypt(const char *, const char *);
char inst[100];
char name[100];
char realm[REALM_SZ + 1];

View File

@@ -8,9 +8,10 @@
#include "protos.h"
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <memory.h>
#include <sys/types.h>
#include <unistd.h>
#include <sys/stat.h>
#include <fcntl.h>