mirror of
https://git.savannah.gnu.org/git/inetutils.git
synced 2026-01-12 00:19:39 +08:00
maint: Re-indent using GNU indent 2.2.13.
This commit is contained in:
@@ -582,7 +582,7 @@ getreply (int expecteof)
|
||||
}
|
||||
|
||||
int
|
||||
empty (fd_set * mask, int sec)
|
||||
empty (fd_set *mask, int sec)
|
||||
{
|
||||
struct timeval t;
|
||||
|
||||
@@ -2011,7 +2011,7 @@ gunique (char *local)
|
||||
}
|
||||
|
||||
void
|
||||
abort_remote (FILE * din)
|
||||
abort_remote (FILE *din)
|
||||
{
|
||||
char buf[BUFSIZ];
|
||||
int nfnd;
|
||||
|
||||
@@ -1318,7 +1318,7 @@ dataconn (const char *name, off_t size, const char *mode)
|
||||
|
||||
NB: Form isn't handled. */
|
||||
static void
|
||||
send_data (FILE * instr, FILE * outstr, off_t blksize)
|
||||
send_data (FILE *instr, FILE *outstr, off_t blksize)
|
||||
{
|
||||
int c, cnt, filefd, netfd;
|
||||
char *buf = MAP_FAILED, *bp;
|
||||
@@ -1483,7 +1483,7 @@ file_err:
|
||||
|
||||
N.B.: Form isn't handled. */
|
||||
static int
|
||||
receive_data (FILE * instr, FILE * outstr, off_t blksize)
|
||||
receive_data (FILE *instr, FILE *outstr, off_t blksize)
|
||||
{
|
||||
int c;
|
||||
int cnt, bare_lfs = 0;
|
||||
|
||||
@@ -211,7 +211,7 @@ pfree:for (argc = 1; gargv[argc] != NULL; argc++)
|
||||
}
|
||||
|
||||
int
|
||||
ftpd_pclose (FILE * iop)
|
||||
ftpd_pclose (FILE *iop)
|
||||
{
|
||||
struct file_pid *fpid = file_pids, *prev_fpid = 0;
|
||||
int status;
|
||||
|
||||
@@ -108,7 +108,7 @@ reapchild (int signo MAYBE_UNUSED)
|
||||
*/
|
||||
int
|
||||
server_mode (const char *pidfile, struct sockaddr *phis_addr,
|
||||
socklen_t * phis_addrlen, char *argv[])
|
||||
socklen_t *phis_addrlen, char *argv[])
|
||||
{
|
||||
int ctl_sock, fd;
|
||||
struct servent *sv;
|
||||
|
||||
@@ -50,7 +50,7 @@ icmp_generic_encode (unsigned char *buffer, size_t bufsize, int type,
|
||||
|
||||
int
|
||||
icmp_generic_decode (unsigned char *buffer, size_t bufsize,
|
||||
struct ip **ipp, icmphdr_t ** icmpp)
|
||||
struct ip **ipp, icmphdr_t **icmpp)
|
||||
{
|
||||
size_t hlen;
|
||||
unsigned short cksum;
|
||||
@@ -87,7 +87,7 @@ icmp_echo_encode (unsigned char *buffer, size_t bufsize, int ident, int seqno)
|
||||
|
||||
int
|
||||
icmp_echo_decode (unsigned char *buffer, size_t bufsize,
|
||||
struct ip **ipp, icmphdr_t ** icmpp)
|
||||
struct ip **ipp, icmphdr_t **icmpp)
|
||||
{
|
||||
return icmp_generic_decode (buffer, bufsize, ipp, icmpp);
|
||||
}
|
||||
|
||||
@@ -88,15 +88,15 @@ int getport (int *, int);
|
||||
|
||||
# if defined KRB5
|
||||
int
|
||||
kcmd (krb5_context * ctx, int *sock, char **ahost, unsigned short rport,
|
||||
kcmd (krb5_context *ctx, int *sock, char **ahost, unsigned short rport,
|
||||
char *locuser, char **remuser, char *cmd, int *fd2p,
|
||||
char *service, const char *realm, krb5_keyblock ** key,
|
||||
char *service, const char *realm, krb5_keyblock **key,
|
||||
struct sockaddr_in *laddr, struct sockaddr_in *faddr, long authopts)
|
||||
# elif defined(SHISHI) /* !KRB5 */
|
||||
int
|
||||
kcmd (Shishi ** h, int *sock, char **ahost, unsigned short rport,
|
||||
kcmd (Shishi **h, int *sock, char **ahost, unsigned short rport,
|
||||
char *locuser, char **remuser, char *cmd, int *fd2p,
|
||||
char *service, const char *realm, Shishi_key ** key,
|
||||
char *service, const char *realm, Shishi_key **key,
|
||||
struct sockaddr_storage *laddr, struct sockaddr_storage *faddr,
|
||||
long authopts, int af)
|
||||
# endif /* SHISHI && !KRB5 */
|
||||
|
||||
@@ -31,9 +31,9 @@
|
||||
|
||||
/* authentication, client side */
|
||||
int
|
||||
kerberos_auth (krb5_context * ctx, int verbose, char **cname,
|
||||
kerberos_auth (krb5_context *ctx, int verbose, char **cname,
|
||||
const char *sname, int sock, char *cmd,
|
||||
unsigned short port, krb5_keyblock ** key, const char *realm)
|
||||
unsigned short port, krb5_keyblock **key, const char *realm)
|
||||
{
|
||||
int rc;
|
||||
char *out, *p;
|
||||
@@ -184,8 +184,8 @@ kerberos_auth (krb5_context * ctx, int verbose, char **cname,
|
||||
|
||||
/* authentication, server side */
|
||||
int
|
||||
get_auth (int infd, krb5_context * ctx, krb5_auth_context * actx,
|
||||
krb5_keyblock ** key, const char **err_msg,
|
||||
get_auth (int infd, krb5_context *ctx, krb5_auth_context *actx,
|
||||
krb5_keyblock **key, const char **err_msg,
|
||||
int *protoversion, int *cksumtype,
|
||||
char **cksum, size_t *cksumlen, char *srvname)
|
||||
{
|
||||
|
||||
@@ -102,7 +102,7 @@ static struct passwd pwstor, *pwd;
|
||||
/* HAVE_GETPWUID_R */
|
||||
|
||||
int
|
||||
krcmd (Shishi ** h, char **ahost, unsigned short rport, char **remuser,
|
||||
krcmd (Shishi **h, char **ahost, unsigned short rport, char **remuser,
|
||||
char *cmd, int *fd2p, const char *realm, int af)
|
||||
{
|
||||
int sock = -1, err = 0;
|
||||
@@ -147,7 +147,7 @@ krcmd (Shishi ** h, char **ahost, unsigned short rport, char **remuser,
|
||||
|
||||
# elif defined(KRB5) /* !SHISHI */
|
||||
int
|
||||
krcmd (krb5_context * ctx, char **ahost, unsigned short rport,
|
||||
krcmd (krb5_context *ctx, char **ahost, unsigned short rport,
|
||||
char **remuser, char *cmd, int *fd2p, const char *realm)
|
||||
{
|
||||
int sock = -1;
|
||||
@@ -178,8 +178,8 @@ krcmd (krb5_context * ctx, char **ahost, unsigned short rport,
|
||||
|
||||
# if defined SHISHI
|
||||
int
|
||||
krcmd_mutual (Shishi ** h, char **ahost, unsigned short rport, char **remuser,
|
||||
char *cmd, int *fd2p, const char *realm, Shishi_key ** key,
|
||||
krcmd_mutual (Shishi **h, char **ahost, unsigned short rport, char **remuser,
|
||||
char *cmd, int *fd2p, const char *realm, Shishi_key **key,
|
||||
int af)
|
||||
{
|
||||
int sock = -1, err = 0;
|
||||
@@ -227,9 +227,9 @@ krcmd_mutual (Shishi ** h, char **ahost, unsigned short rport, char **remuser,
|
||||
|
||||
# elif defined(KRB5) /* !SHISHI */
|
||||
int
|
||||
krcmd_mutual (krb5_context * ctx, char **ahost, unsigned short rport,
|
||||
krcmd_mutual (krb5_context *ctx, char **ahost, unsigned short rport,
|
||||
char **remuser, char *cmd, int *fd2p, const char *realm,
|
||||
krb5_keyblock ** key)
|
||||
krb5_keyblock **key)
|
||||
{
|
||||
int sock;
|
||||
krb5_error_code err = 0;
|
||||
|
||||
@@ -29,9 +29,9 @@
|
||||
|
||||
/* shishi authentication, client side */
|
||||
int
|
||||
shishi_auth (Shishi ** handle, int verbose, char **cname,
|
||||
shishi_auth (Shishi **handle, int verbose, char **cname,
|
||||
const char *sname, int sock, char *cmd,
|
||||
unsigned short port, Shishi_key ** enckey, const char *realm)
|
||||
unsigned short port, Shishi_key **enckey, const char *realm)
|
||||
{
|
||||
Shishi_ap *ap;
|
||||
Shishi_tkt *tkt;
|
||||
@@ -272,8 +272,8 @@ senderror (int s, char type, char *buf)
|
||||
|
||||
/* shishi authentication, server side */
|
||||
int
|
||||
get_auth (int infd, Shishi ** handle, Shishi_ap ** ap,
|
||||
Shishi_key ** enckey, const char **err_msg, int *protoversion,
|
||||
get_auth (int infd, Shishi **handle, Shishi_ap **ap,
|
||||
Shishi_key **enckey, const char **err_msg, int *protoversion,
|
||||
int *cksumtype, char **cksum, size_t *cksumlen, char *srvname)
|
||||
{
|
||||
Shishi_key *key;
|
||||
@@ -569,8 +569,8 @@ get_auth (int infd, Shishi ** handle, Shishi_ap ** ap,
|
||||
|
||||
/* read encrypted data on socket */
|
||||
int
|
||||
readenc (Shishi * h, int sock, char *buf, int *len, shishi_ivector * iv,
|
||||
Shishi_key * enckey, int proto)
|
||||
readenc (Shishi *h, int sock, char *buf, int *len, shishi_ivector *iv,
|
||||
Shishi_key *enckey, int proto)
|
||||
{
|
||||
char *out;
|
||||
char *outbis;
|
||||
@@ -695,8 +695,8 @@ readenc (Shishi * h, int sock, char *buf, int *len, shishi_ivector * iv,
|
||||
|
||||
/* write encrypted data to socket */
|
||||
int
|
||||
writeenc (Shishi * h, int sock, char *buf, int wlen, int *len,
|
||||
shishi_ivector * iv, Shishi_key * enckey, int proto)
|
||||
writeenc (Shishi *h, int sock, char *buf, int wlen, int *len,
|
||||
shishi_ivector *iv, Shishi_key *enckey, int proto)
|
||||
{
|
||||
char *out;
|
||||
char *bufbis;
|
||||
|
||||
@@ -130,7 +130,7 @@ rw_init (int x)
|
||||
/* if true, convert to ascii */
|
||||
/* file opened for read */
|
||||
int
|
||||
readit (FILE * file, struct tftphdr **dpp, int convert)
|
||||
readit (FILE *file, struct tftphdr **dpp, int convert)
|
||||
{
|
||||
struct bf *b;
|
||||
|
||||
@@ -152,7 +152,7 @@ readit (FILE * file, struct tftphdr **dpp, int convert)
|
||||
/* FILE *file; file opened for read */
|
||||
/* int convert; if true, convert to ascii */
|
||||
void
|
||||
read_ahead (FILE * file, int convert)
|
||||
read_ahead (FILE *file, int convert)
|
||||
{
|
||||
register int i;
|
||||
register char *p;
|
||||
@@ -206,7 +206,7 @@ read_ahead (FILE * file, int convert)
|
||||
available.
|
||||
*/
|
||||
int
|
||||
writeit (FILE * file, struct tftphdr **dpp, int ct, int convert)
|
||||
writeit (FILE *file, struct tftphdr **dpp, int ct, int convert)
|
||||
{
|
||||
bfs[current].counter = ct; /* set size of data to write */
|
||||
current = !current; /* switch to other buffer */
|
||||
@@ -224,7 +224,7 @@ writeit (FILE * file, struct tftphdr **dpp, int ct, int convert)
|
||||
* CR followed by anything else. In this case we leave it alone.
|
||||
*/
|
||||
int
|
||||
write_behind (FILE * file, int convert)
|
||||
write_behind (FILE *file, int convert)
|
||||
{
|
||||
char *buf;
|
||||
int count;
|
||||
|
||||
20
libls/cmp.c
20
libls/cmp.c
@@ -59,19 +59,19 @@
|
||||
#include "extern.h"
|
||||
|
||||
int
|
||||
namecmp (const FTSENT * a, const FTSENT * b)
|
||||
namecmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (strcmp (a->fts_name, b->fts_name));
|
||||
}
|
||||
|
||||
int
|
||||
revnamecmp (const FTSENT * a, const FTSENT * b)
|
||||
revnamecmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (strcmp (b->fts_name, a->fts_name));
|
||||
}
|
||||
|
||||
int
|
||||
modcmp (const FTSENT * a, const FTSENT * b)
|
||||
modcmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
if (b->fts_statp->st_mtime > a->fts_statp->st_mtime ||
|
||||
#ifdef HAVE_STRUCT_STAT_ST_MTIM_TV_NSEC
|
||||
@@ -102,13 +102,13 @@ modcmp (const FTSENT * a, const FTSENT * b)
|
||||
}
|
||||
|
||||
int
|
||||
revmodcmp (const FTSENT * a, const FTSENT * b)
|
||||
revmodcmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (-modcmp (a, b));
|
||||
}
|
||||
|
||||
int
|
||||
acccmp (const FTSENT * a, const FTSENT * b)
|
||||
acccmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
if (b->fts_statp->st_atime > a->fts_statp->st_atime ||
|
||||
#ifdef HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC
|
||||
@@ -139,13 +139,13 @@ acccmp (const FTSENT * a, const FTSENT * b)
|
||||
}
|
||||
|
||||
int
|
||||
revacccmp (const FTSENT * a, const FTSENT * b)
|
||||
revacccmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (-acccmp (a, b));
|
||||
}
|
||||
|
||||
int
|
||||
statcmp (const FTSENT * a, const FTSENT * b)
|
||||
statcmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
if (b->fts_statp->st_ctime > a->fts_statp->st_ctime ||
|
||||
#ifdef HAVE_STRUCT_STAT_ST_CTIM_TV_NSEC
|
||||
@@ -176,13 +176,13 @@ statcmp (const FTSENT * a, const FTSENT * b)
|
||||
}
|
||||
|
||||
int
|
||||
revstatcmp (const FTSENT * a, const FTSENT * b)
|
||||
revstatcmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (-statcmp (a, b));
|
||||
}
|
||||
|
||||
int
|
||||
sizecmp (const FTSENT * a, const FTSENT * b)
|
||||
sizecmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
if (b->fts_statp->st_size > a->fts_statp->st_size)
|
||||
return (1);
|
||||
@@ -193,7 +193,7 @@ sizecmp (const FTSENT * a, const FTSENT * b)
|
||||
}
|
||||
|
||||
int
|
||||
revsizecmp (const FTSENT * a, const FTSENT * b)
|
||||
revsizecmp (const FTSENT *a, const FTSENT *b)
|
||||
{
|
||||
return (-sizecmp (a, b));
|
||||
}
|
||||
|
||||
@@ -432,7 +432,7 @@ traverse (int argc, char **argv, int options)
|
||||
* points to the parent directory of the display list.
|
||||
*/
|
||||
static void
|
||||
display (FTSENT * p, FTSENT * list)
|
||||
display (FTSENT *p, FTSENT *list)
|
||||
{
|
||||
struct stat *sp;
|
||||
DISPLAY d;
|
||||
@@ -611,7 +611,7 @@ display (FTSENT * p, FTSENT * list)
|
||||
* All other levels use the sort function. Error entries remain unsorted.
|
||||
*/
|
||||
static int
|
||||
mastercmp (const FTSENT ** a, const FTSENT ** b)
|
||||
mastercmp (const FTSENT **a, const FTSENT **b)
|
||||
{
|
||||
int a_info, b_info;
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ static int compute_columns (DISPLAY *, int *);
|
||||
#define IS_NOPRINT(p) ((p)->fts_number == NO_PRINT)
|
||||
|
||||
void
|
||||
printscol (DISPLAY * dp)
|
||||
printscol (DISPLAY *dp)
|
||||
{
|
||||
FTSENT *p;
|
||||
|
||||
@@ -109,7 +109,7 @@ printscol (DISPLAY * dp)
|
||||
}
|
||||
|
||||
void
|
||||
printlong (DISPLAY * dp)
|
||||
printlong (DISPLAY *dp)
|
||||
{
|
||||
struct stat *sp;
|
||||
FTSENT *p;
|
||||
@@ -160,7 +160,7 @@ printlong (DISPLAY * dp)
|
||||
}
|
||||
|
||||
static int
|
||||
compute_columns (DISPLAY * dp, int *pnum)
|
||||
compute_columns (DISPLAY *dp, int *pnum)
|
||||
{
|
||||
int colwidth;
|
||||
extern int termwidth;
|
||||
@@ -188,7 +188,7 @@ compute_columns (DISPLAY * dp, int *pnum)
|
||||
}
|
||||
|
||||
void
|
||||
printcol (DISPLAY * dp)
|
||||
printcol (DISPLAY *dp)
|
||||
{
|
||||
static FTSENT **array;
|
||||
static int lastentries = -1;
|
||||
@@ -246,7 +246,7 @@ printcol (DISPLAY * dp)
|
||||
* return # of characters printed, no trailing characters.
|
||||
*/
|
||||
static int
|
||||
printaname (FTSENT * p, unsigned long inodefield, unsigned long sizefield)
|
||||
printaname (FTSENT *p, unsigned long inodefield, unsigned long sizefield)
|
||||
{
|
||||
struct stat *sp;
|
||||
int chcnt;
|
||||
@@ -292,7 +292,7 @@ printtime (time_t ftime)
|
||||
}
|
||||
|
||||
void
|
||||
printacol (DISPLAY * dp)
|
||||
printacol (DISPLAY *dp)
|
||||
{
|
||||
FTSENT *p;
|
||||
int chcnt, col, colwidth;
|
||||
@@ -323,7 +323,7 @@ printacol (DISPLAY * dp)
|
||||
}
|
||||
|
||||
void
|
||||
printstream (DISPLAY * dp)
|
||||
printstream (DISPLAY *dp)
|
||||
{
|
||||
extern int termwidth;
|
||||
FTSENT *p;
|
||||
@@ -382,7 +382,7 @@ printtype (u_int mode)
|
||||
}
|
||||
|
||||
static void
|
||||
printlink (FTSENT * p)
|
||||
printlink (FTSENT *p)
|
||||
{
|
||||
int lnklen;
|
||||
#ifndef MAXPATHLEN
|
||||
|
||||
@@ -93,7 +93,7 @@ flags_to_string (u_int flags, char *def)
|
||||
* to the offending token.
|
||||
*/
|
||||
int
|
||||
string_to_flags (char **stringp, u_int * setp, u_int * clrp)
|
||||
string_to_flags (char **stringp, u_int *setp, u_int *clrp)
|
||||
{
|
||||
if (setp)
|
||||
*setp = 0;
|
||||
|
||||
@@ -650,7 +650,7 @@ auth_sendname (char *name, int len)
|
||||
}
|
||||
|
||||
void
|
||||
auth_finished (TN_Authenticator * ap, int result)
|
||||
auth_finished (TN_Authenticator *ap, int result)
|
||||
{
|
||||
if (ap && ap->cleanup)
|
||||
(*ap->cleanup) (ap);
|
||||
|
||||
@@ -151,7 +151,7 @@ static int des_set_parity (Block b);
|
||||
|
||||
# ifdef SHISHI
|
||||
static void
|
||||
shishi_des_ecb_encrypt (Shishi * h, const unsigned char key[sizeof (Block)],
|
||||
shishi_des_ecb_encrypt (Shishi *h, const unsigned char key[sizeof (Block)],
|
||||
const unsigned char *in, unsigned char *out)
|
||||
{
|
||||
char *tmp;
|
||||
@@ -446,14 +446,14 @@ fb64_reply (unsigned char *data, int cnt, struct fb *fbp)
|
||||
}
|
||||
|
||||
void
|
||||
cfb64_session (Session_Key * key, int server)
|
||||
cfb64_session (Session_Key *key, int server)
|
||||
{
|
||||
fb64_session (key, server, &fb[CFB]);
|
||||
}
|
||||
|
||||
# ifdef ENCTYPE_DES_OFB64
|
||||
void
|
||||
ofb64_session (Session_Key * key, int server)
|
||||
ofb64_session (Session_Key *key, int server)
|
||||
{
|
||||
fb64_session (key, server, &fb[OFB]);
|
||||
}
|
||||
@@ -461,7 +461,7 @@ ofb64_session (Session_Key * key, int server)
|
||||
/* ENCTYPE_DES_OFB64 */
|
||||
|
||||
static void
|
||||
fb64_session (Session_Key * key, int server, struct fb *fbp)
|
||||
fb64_session (Session_Key *key, int server, struct fb *fbp)
|
||||
{
|
||||
size_t offset;
|
||||
unsigned char *derived_key;
|
||||
|
||||
@@ -707,7 +707,7 @@ encrypt_start (unsigned char *data MAYBE_UNUSED, int cnt MAYBE_UNUSED)
|
||||
}
|
||||
|
||||
void
|
||||
encrypt_session_key (Session_Key * key, int server)
|
||||
encrypt_session_key (Session_Key *key, int server)
|
||||
{
|
||||
Encryptions *ep = encryptions;
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ char *dest_realm = NULL;
|
||||
extern void printsub (char, unsigned char *, int);
|
||||
|
||||
static int
|
||||
Data (TN_Authenticator * ap, int type, krb5_pointer d, int c)
|
||||
Data (TN_Authenticator *ap, int type, krb5_pointer d, int c)
|
||||
{
|
||||
unsigned char *p = str_data + 4;
|
||||
unsigned char *cd = (unsigned char *) d;
|
||||
@@ -118,7 +118,7 @@ Data (TN_Authenticator * ap, int type, krb5_pointer d, int c)
|
||||
|
||||
/* FIXME: Reverse return code! */
|
||||
int
|
||||
kerberos5_init (TN_Authenticator * ap MAYBE_UNUSED, int server)
|
||||
kerberos5_init (TN_Authenticator *ap MAYBE_UNUSED, int server)
|
||||
{
|
||||
str_data[3] = server ? TELQUAL_REPLY : TELQUAL_IS;
|
||||
if (telnet_context == 0 && krb5_init_context (&telnet_context))
|
||||
@@ -149,7 +149,7 @@ kerberos5_cleanup ()
|
||||
# ifdef ENCRYPTION
|
||||
|
||||
void
|
||||
encryption_init (krb5_creds * creds)
|
||||
encryption_init (krb5_creds *creds)
|
||||
{
|
||||
krb5_keyblock *newkey = 0;
|
||||
|
||||
@@ -193,7 +193,7 @@ encryption_init (krb5_creds * creds)
|
||||
# endif
|
||||
|
||||
int
|
||||
kerberos5_send (TN_Authenticator * ap)
|
||||
kerberos5_send (TN_Authenticator *ap)
|
||||
{
|
||||
krb5_error_code r;
|
||||
krb5_ccache ccache;
|
||||
@@ -320,7 +320,7 @@ kerberos5_send (TN_Authenticator * ap)
|
||||
|
||||
# ifdef ENCRYPTION
|
||||
void
|
||||
telnet_encrypt_key (Session_Key * skey)
|
||||
telnet_encrypt_key (Session_Key *skey)
|
||||
{
|
||||
if (session_key)
|
||||
{
|
||||
@@ -335,7 +335,7 @@ telnet_encrypt_key (Session_Key * skey)
|
||||
# endif
|
||||
|
||||
void
|
||||
kerberos5_reply (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
kerberos5_reply (TN_Authenticator *ap, unsigned char *data, int cnt)
|
||||
{
|
||||
# ifdef ENCRYPTION
|
||||
Session_Key skey;
|
||||
@@ -425,7 +425,7 @@ kerberos5_reply (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
}
|
||||
|
||||
int
|
||||
kerberos5_status (TN_Authenticator * ap MAYBE_UNUSED,
|
||||
kerberos5_status (TN_Authenticator *ap MAYBE_UNUSED,
|
||||
char *name, size_t len, int level)
|
||||
{
|
||||
if (level < AUTH_USER)
|
||||
@@ -443,7 +443,7 @@ kerberos5_status (TN_Authenticator * ap MAYBE_UNUSED,
|
||||
}
|
||||
|
||||
static int
|
||||
kerberos5_is_auth (TN_Authenticator * ap, unsigned char *data, int cnt,
|
||||
kerberos5_is_auth (TN_Authenticator *ap, unsigned char *data, int cnt,
|
||||
char *errbuf, int errbuflen)
|
||||
{
|
||||
int r = 0;
|
||||
@@ -639,7 +639,7 @@ kerberos5_is_auth (TN_Authenticator * ap, unsigned char *data, int cnt,
|
||||
|
||||
# ifdef FORWARD
|
||||
static int
|
||||
kerberos5_is_forward (TN_Authenticator * ap, unsigned char *data, int cnt,
|
||||
kerberos5_is_forward (TN_Authenticator *ap, unsigned char *data, int cnt,
|
||||
char *errbuf, int errbuflen)
|
||||
{
|
||||
int r = 0;
|
||||
@@ -670,7 +670,7 @@ kerberos5_is_forward (TN_Authenticator * ap, unsigned char *data, int cnt,
|
||||
# endif
|
||||
|
||||
void
|
||||
kerberos5_is (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
kerberos5_is (TN_Authenticator *ap, unsigned char *data, int cnt)
|
||||
{
|
||||
int r = 0;
|
||||
char errbuf[512];
|
||||
@@ -794,7 +794,7 @@ kerberos5_printsub (unsigned char *data, int cnt, char *buf, int buflen)
|
||||
# ifdef FORWARD
|
||||
|
||||
void
|
||||
kerberos5_forward (TN_Authenticator * ap)
|
||||
kerberos5_forward (TN_Authenticator *ap)
|
||||
{
|
||||
krb5_error_code r;
|
||||
krb5_ccache ccache;
|
||||
|
||||
@@ -62,7 +62,7 @@ Shishi_ap *auth_handle;
|
||||
extern void printsub (char, unsigned char *, int);
|
||||
|
||||
static int
|
||||
Data (TN_Authenticator * ap, int type, void *d, int c)
|
||||
Data (TN_Authenticator *ap, int type, void *d, int c)
|
||||
{
|
||||
unsigned char *p = str_data + 4;
|
||||
unsigned char *cd = (unsigned char *) d;
|
||||
@@ -100,7 +100,7 @@ Shishi *shishi_telnet = NULL;
|
||||
|
||||
/* FIXME: Reverse return code! */
|
||||
int
|
||||
krb5shishi_init (TN_Authenticator * ap MAYBE_UNUSED, int server)
|
||||
krb5shishi_init (TN_Authenticator *ap MAYBE_UNUSED, int server)
|
||||
{
|
||||
if (server)
|
||||
str_data[3] = TELQUAL_REPLY;
|
||||
@@ -134,7 +134,7 @@ delayed_shishi_init (void)
|
||||
}
|
||||
|
||||
void
|
||||
krb5shishi_cleanup (TN_Authenticator * ap MAYBE_UNUSED)
|
||||
krb5shishi_cleanup (TN_Authenticator *ap MAYBE_UNUSED)
|
||||
{
|
||||
if (shishi_handle == NULL)
|
||||
return;
|
||||
@@ -144,7 +144,7 @@ krb5shishi_cleanup (TN_Authenticator * ap MAYBE_UNUSED)
|
||||
}
|
||||
|
||||
int
|
||||
krb5shishi_send (TN_Authenticator * ap)
|
||||
krb5shishi_send (TN_Authenticator *ap)
|
||||
{
|
||||
int ap_opts;
|
||||
char type_check[2];
|
||||
@@ -294,7 +294,7 @@ krb5shishi_send (TN_Authenticator * ap)
|
||||
|
||||
# ifdef ENCRYPTION
|
||||
static void
|
||||
shishi_init_key (Session_Key * skey, int type)
|
||||
shishi_init_key (Session_Key *skey, int type)
|
||||
{
|
||||
int32_t etype = shishi_key_type (enckey);
|
||||
|
||||
@@ -311,7 +311,7 @@ shishi_init_key (Session_Key * skey, int type)
|
||||
# endif
|
||||
|
||||
void
|
||||
krb5shishi_reply (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
krb5shishi_reply (TN_Authenticator *ap, unsigned char *data, int cnt)
|
||||
{
|
||||
static int mutual_complete = 0;
|
||||
# ifdef ENCRYPTION
|
||||
@@ -393,7 +393,7 @@ krb5shishi_reply (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
}
|
||||
|
||||
int
|
||||
krb5shishi_status (TN_Authenticator * ap MAYBE_UNUSED,
|
||||
krb5shishi_status (TN_Authenticator *ap MAYBE_UNUSED,
|
||||
char *name, size_t len, int level)
|
||||
{
|
||||
int status;
|
||||
@@ -416,7 +416,7 @@ krb5shishi_status (TN_Authenticator * ap MAYBE_UNUSED,
|
||||
}
|
||||
|
||||
static int
|
||||
krb5shishi_is_auth (TN_Authenticator * a, unsigned char *data, int cnt,
|
||||
krb5shishi_is_auth (TN_Authenticator *a, unsigned char *data, int cnt,
|
||||
char *errbuf, int errbuflen)
|
||||
{
|
||||
Shishi_key *key;
|
||||
@@ -628,7 +628,7 @@ krb5shishi_is_auth (TN_Authenticator * a, unsigned char *data, int cnt,
|
||||
}
|
||||
|
||||
void
|
||||
krb5shishi_is (TN_Authenticator * ap, unsigned char *data, int cnt)
|
||||
krb5shishi_is (TN_Authenticator *ap, unsigned char *data, int cnt)
|
||||
{
|
||||
int r = 0;
|
||||
char errbuf[512];
|
||||
|
||||
@@ -45,7 +45,7 @@ static int useless_ident = 0; /* Relevant at least for Linux. */
|
||||
static size_t _ping_packetsize (PING * p);
|
||||
|
||||
size_t
|
||||
_ping_packetsize (PING * p)
|
||||
_ping_packetsize (PING *p)
|
||||
{
|
||||
if (p->ping_type == ICMP_TIMESTAMP || p->ping_type == ICMP_TIMESTAMPREPLY)
|
||||
return ICMP_TSLEN;
|
||||
@@ -124,7 +124,7 @@ ping_init (int type, int ident)
|
||||
}
|
||||
|
||||
void
|
||||
ping_reset (PING * p)
|
||||
ping_reset (PING *p)
|
||||
{
|
||||
p->ping_num_xmit = 0;
|
||||
p->ping_num_recv = 0;
|
||||
@@ -132,13 +132,13 @@ ping_reset (PING * p)
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_type (PING * p, int type)
|
||||
ping_set_type (PING *p, int type)
|
||||
{
|
||||
p->ping_type = type;
|
||||
}
|
||||
|
||||
int
|
||||
ping_xmit (PING * p)
|
||||
ping_xmit (PING *p)
|
||||
{
|
||||
int i, buflen;
|
||||
|
||||
@@ -190,7 +190,7 @@ ping_xmit (PING * p)
|
||||
}
|
||||
|
||||
static int
|
||||
my_echo_reply (PING * p, icmphdr_t * icmp)
|
||||
my_echo_reply (PING *p, icmphdr_t *icmp)
|
||||
{
|
||||
struct ip *orig_ip = &icmp->icmp_ip;
|
||||
icmphdr_t *orig_icmp = (icmphdr_t *) (orig_ip + 1);
|
||||
@@ -202,7 +202,7 @@ my_echo_reply (PING * p, icmphdr_t * icmp)
|
||||
}
|
||||
|
||||
int
|
||||
ping_recv (PING * p)
|
||||
ping_recv (PING *p)
|
||||
{
|
||||
socklen_t fromlen = sizeof (p->ping_from.ping_sockaddr);
|
||||
int n, rc;
|
||||
@@ -278,20 +278,20 @@ ping_recv (PING * p)
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_event_handler (PING * ping, ping_efp pf, void *closure)
|
||||
ping_set_event_handler (PING *ping, ping_efp pf, void *closure)
|
||||
{
|
||||
ping->ping_event.handler = pf;
|
||||
ping->ping_closure = closure;
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_packetsize (PING * ping, size_t size)
|
||||
ping_set_packetsize (PING *ping, size_t size)
|
||||
{
|
||||
ping->ping_datalen = size;
|
||||
}
|
||||
|
||||
int
|
||||
ping_set_dest (PING * ping, const char *host)
|
||||
ping_set_dest (PING *ping, const char *host)
|
||||
{
|
||||
#if HAVE_DECL_GETADDRINFO
|
||||
int rc;
|
||||
|
||||
@@ -382,7 +382,7 @@ sig_int (int signal MAYBE_UNUSED)
|
||||
}
|
||||
|
||||
int
|
||||
ping_run (PING * ping, int (*finish) ())
|
||||
ping_run (PING *ping, int (*finish) ())
|
||||
{
|
||||
fd_set fdset;
|
||||
int fdmax;
|
||||
@@ -497,7 +497,7 @@ ping_run (PING * ping, int (*finish) ())
|
||||
}
|
||||
|
||||
int
|
||||
send_echo (PING * ping)
|
||||
send_echo (PING *ping)
|
||||
{
|
||||
size_t off = 0;
|
||||
int rc;
|
||||
|
||||
14
ping/ping6.c
14
ping/ping6.c
@@ -325,7 +325,7 @@ sig_int (int signal MAYBE_UNUSED)
|
||||
}
|
||||
|
||||
static int
|
||||
ping_run (PING * ping, int (*finish) ())
|
||||
ping_run (PING *ping, int (*finish) ())
|
||||
{
|
||||
fd_set fdset;
|
||||
int fdmax;
|
||||
@@ -443,7 +443,7 @@ ping_run (PING * ping, int (*finish) ())
|
||||
}
|
||||
|
||||
static int
|
||||
send_echo (PING * ping)
|
||||
send_echo (PING *ping)
|
||||
{
|
||||
size_t off = 0;
|
||||
int rc;
|
||||
@@ -546,7 +546,7 @@ ping_echo (char *hostname)
|
||||
}
|
||||
|
||||
static void
|
||||
ping_reset (PING * p)
|
||||
ping_reset (PING *p)
|
||||
{
|
||||
p->ping_num_xmit = 0;
|
||||
p->ping_num_recv = 0;
|
||||
@@ -895,7 +895,7 @@ ping_init (int type MAYBE_UNUSED, int ident)
|
||||
}
|
||||
|
||||
static int
|
||||
ping_xmit (PING * p)
|
||||
ping_xmit (PING *p)
|
||||
{
|
||||
int i, buflen;
|
||||
struct icmp6_hdr *icmp6;
|
||||
@@ -933,7 +933,7 @@ ping_xmit (PING * p)
|
||||
}
|
||||
|
||||
static int
|
||||
my_echo_reply (PING * p, struct icmp6_hdr *icmp6)
|
||||
my_echo_reply (PING *p, struct icmp6_hdr *icmp6)
|
||||
{
|
||||
struct ip6_hdr *orig_ip = (struct ip6_hdr *) (icmp6 + 1);
|
||||
struct icmp6_hdr *orig_icmp = (struct icmp6_hdr *) (orig_ip + 1);
|
||||
@@ -946,7 +946,7 @@ my_echo_reply (PING * p, struct icmp6_hdr *icmp6)
|
||||
}
|
||||
|
||||
static int
|
||||
ping_recv (PING * p)
|
||||
ping_recv (PING *p)
|
||||
{
|
||||
int dupflag, n;
|
||||
int hops = -1;
|
||||
@@ -1018,7 +1018,7 @@ ping_recv (PING * p)
|
||||
}
|
||||
|
||||
static int
|
||||
ping_set_dest (PING * ping, const char *host)
|
||||
ping_set_dest (PING *ping, const char *host)
|
||||
{
|
||||
int err;
|
||||
struct addrinfo *result, hints;
|
||||
|
||||
@@ -74,7 +74,7 @@ ping_address (char *hostname)
|
||||
int
|
||||
recv_address (int code, void *closure,
|
||||
struct sockaddr_in *dest, struct sockaddr_in *from,
|
||||
struct ip *ip, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
switch (code)
|
||||
{
|
||||
@@ -93,7 +93,7 @@ void
|
||||
print_address (int dupflag, void *closure MAYBE_UNUSED,
|
||||
struct sockaddr_in *dest MAYBE_UNUSED,
|
||||
struct sockaddr_in *from,
|
||||
struct ip *ip MAYBE_UNUSED, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip MAYBE_UNUSED, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
struct in_addr addr;
|
||||
|
||||
|
||||
@@ -168,7 +168,7 @@ ping_cvt_time (char *buf, size_t buflen, n_time t)
|
||||
}
|
||||
|
||||
int
|
||||
_ping_setbuf (PING * p, bool use_ipv6)
|
||||
_ping_setbuf (PING *p, bool use_ipv6)
|
||||
{
|
||||
if (!p->ping_buffer)
|
||||
{
|
||||
@@ -187,7 +187,7 @@ _ping_setbuf (PING * p, bool use_ipv6)
|
||||
}
|
||||
|
||||
int
|
||||
ping_set_data (PING * p, void *data, size_t off, size_t len, bool use_ipv6)
|
||||
ping_set_data (PING *p, void *data, size_t off, size_t len, bool use_ipv6)
|
||||
{
|
||||
icmphdr_t *icmp;
|
||||
|
||||
@@ -203,25 +203,25 @@ ping_set_data (PING * p, void *data, size_t off, size_t len, bool use_ipv6)
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_count (PING * ping, size_t count)
|
||||
ping_set_count (PING *ping, size_t count)
|
||||
{
|
||||
ping->ping_count = count;
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_sockopt (PING * ping, int opt, void *val, int valsize)
|
||||
ping_set_sockopt (PING *ping, int opt, void *val, int valsize)
|
||||
{
|
||||
setsockopt (ping->ping_fd, SOL_SOCKET, opt, (char *) &val, valsize);
|
||||
}
|
||||
|
||||
void
|
||||
ping_set_interval (PING * ping, size_t interval)
|
||||
ping_set_interval (PING *ping, size_t interval)
|
||||
{
|
||||
ping->ping_interval = interval;
|
||||
}
|
||||
|
||||
void
|
||||
_ping_freebuf (PING * p)
|
||||
_ping_freebuf (PING *p)
|
||||
{
|
||||
if (p->ping_buffer)
|
||||
{
|
||||
@@ -236,7 +236,7 @@ _ping_freebuf (PING * p)
|
||||
}
|
||||
|
||||
void
|
||||
ping_unset_data (PING * p)
|
||||
ping_unset_data (PING *p)
|
||||
{
|
||||
_ping_freebuf (p);
|
||||
}
|
||||
|
||||
@@ -154,7 +154,7 @@ ping_echo (char *hostname)
|
||||
int
|
||||
handler (int code, void *closure,
|
||||
struct sockaddr_in *dest, struct sockaddr_in *from,
|
||||
struct ip *ip, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
switch (code)
|
||||
{
|
||||
@@ -174,7 +174,7 @@ int
|
||||
print_echo (int dupflag, struct ping_stat *ping_stat,
|
||||
struct sockaddr_in *dest MAYBE_UNUSED,
|
||||
struct sockaddr_in *from,
|
||||
struct ip *ip, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
int hlen;
|
||||
struct timeval tv;
|
||||
@@ -336,7 +336,7 @@ print_ip_header (struct ip *ip)
|
||||
}
|
||||
|
||||
void
|
||||
print_ip_data (icmphdr_t * icmp, void *data MAYBE_UNUSED)
|
||||
print_ip_data (icmphdr_t *icmp, void *data MAYBE_UNUSED)
|
||||
{
|
||||
int hlen;
|
||||
unsigned char *cp;
|
||||
@@ -368,7 +368,7 @@ print_ip_data (icmphdr_t * icmp, void *data MAYBE_UNUSED)
|
||||
}
|
||||
|
||||
static void
|
||||
print_icmp (icmphdr_t * icmp, void *data)
|
||||
print_icmp (icmphdr_t *icmp, void *data)
|
||||
{
|
||||
print_icmp_code (icmp->icmp_type, icmp->icmp_code, data);
|
||||
if (options & OPT_VERBOSE)
|
||||
@@ -376,7 +376,7 @@ print_icmp (icmphdr_t * icmp, void *data)
|
||||
}
|
||||
|
||||
static void
|
||||
print_parameterprob (icmphdr_t * icmp, void *data)
|
||||
print_parameterprob (icmphdr_t *icmp, void *data)
|
||||
{
|
||||
printf ("Parameter problem: IP address = %s\n",
|
||||
inet_ntoa (icmp->icmp_gwaddr));
|
||||
@@ -403,7 +403,7 @@ struct icmp_diag icmp_diag[] = {
|
||||
|
||||
void
|
||||
print_icmp_header (struct sockaddr_in *from,
|
||||
struct ip *ip, icmphdr_t * icmp, int len)
|
||||
struct ip *ip, icmphdr_t *icmp, int len)
|
||||
{
|
||||
int hlen;
|
||||
struct ip *orig_ip;
|
||||
|
||||
@@ -73,7 +73,7 @@ ping_timestamp (char *hostname)
|
||||
int
|
||||
recv_timestamp (int code, void *closure,
|
||||
struct sockaddr_in *dest, struct sockaddr_in *from,
|
||||
struct ip *ip, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
switch (code)
|
||||
{
|
||||
@@ -93,7 +93,7 @@ void
|
||||
print_timestamp (int dupflag, void *closure MAYBE_UNUSED,
|
||||
struct sockaddr_in *dest MAYBE_UNUSED,
|
||||
struct sockaddr_in *from,
|
||||
struct ip *ip MAYBE_UNUSED, icmphdr_t * icmp, int datalen)
|
||||
struct ip *ip MAYBE_UNUSED, icmphdr_t *icmp, int datalen)
|
||||
{
|
||||
char timestr[16];
|
||||
|
||||
|
||||
@@ -167,7 +167,7 @@ main (int argc, char *argv[])
|
||||
}
|
||||
|
||||
static void
|
||||
get_name (const hostname_arguments * const args)
|
||||
get_name (const hostname_arguments *const args)
|
||||
{
|
||||
char *sname, *name;
|
||||
|
||||
@@ -221,7 +221,7 @@ get_name (const hostname_arguments * const args)
|
||||
}
|
||||
|
||||
static void
|
||||
set_name (const hostname_arguments * const args)
|
||||
set_name (const hostname_arguments *const args)
|
||||
{
|
||||
char *hostname_new;
|
||||
int status;
|
||||
|
||||
@@ -377,7 +377,7 @@ signal_set_handler (int signo, void (*handler) (int))
|
||||
}
|
||||
|
||||
void
|
||||
signal_block (SIGSTATUS * old_status)
|
||||
signal_block (SIGSTATUS *old_status)
|
||||
{
|
||||
#ifdef HAVE_SIGACTION
|
||||
sigset_t sigs;
|
||||
@@ -395,7 +395,7 @@ signal_block (SIGSTATUS * old_status)
|
||||
}
|
||||
|
||||
void
|
||||
signal_unblock (SIGSTATUS * status)
|
||||
signal_unblock (SIGSTATUS *status)
|
||||
{
|
||||
#ifdef HAVE_SIGACTION
|
||||
if (status)
|
||||
@@ -925,7 +925,7 @@ setconfig (const char *file)
|
||||
}
|
||||
|
||||
void
|
||||
endconfig (FILE * fconfig)
|
||||
endconfig (FILE *fconfig)
|
||||
{
|
||||
if (fconfig)
|
||||
fclose (fconfig);
|
||||
@@ -980,7 +980,7 @@ next_node_sep (struct servtab *sep)
|
||||
}
|
||||
|
||||
struct servtab *
|
||||
getconfigent (FILE * fconfig, const char *file, size_t *line)
|
||||
getconfigent (FILE *fconfig, const char *file, size_t *line)
|
||||
{
|
||||
static struct servtab serv;
|
||||
struct servtab *sep = &serv;
|
||||
|
||||
@@ -70,7 +70,7 @@ static int host_family = AF_INET;
|
||||
|
||||
|
||||
int
|
||||
decode (char *name, CODE * codetab, const char *what)
|
||||
decode (char *name, CODE *codetab, const char *what)
|
||||
{
|
||||
CODE *cp;
|
||||
|
||||
|
||||
@@ -1490,7 +1490,7 @@ susystem (char *s, int userid)
|
||||
}
|
||||
|
||||
BUF *
|
||||
allocbuf (BUF * bp, int fd, int blksize)
|
||||
allocbuf (BUF *bp, int fd, int blksize)
|
||||
{
|
||||
struct stat stb;
|
||||
size_t size;
|
||||
|
||||
@@ -771,7 +771,7 @@ struct termios ixon_state;
|
||||
struct termios nott;
|
||||
|
||||
void
|
||||
doit (sigset_t * osmask)
|
||||
doit (sigset_t *osmask)
|
||||
{
|
||||
int i;
|
||||
struct sigaction sa;
|
||||
@@ -1288,7 +1288,7 @@ oob (int signo MAYBE_UNUSED)
|
||||
|
||||
/* reader: read from remote: line -> 1 */
|
||||
int
|
||||
reader (sigset_t * osmask)
|
||||
reader (sigset_t *osmask)
|
||||
{
|
||||
pid_t pid;
|
||||
int n, remaining;
|
||||
|
||||
@@ -632,7 +632,7 @@ try_connect:
|
||||
}
|
||||
|
||||
void
|
||||
talk (int null_input_option, sigset_t * osigs, pid_t pid, int rem)
|
||||
talk (int null_input_option, sigset_t *osigs, pid_t pid, int rem)
|
||||
{
|
||||
int cc, wc;
|
||||
fd_set readfrom, ready, rembits;
|
||||
|
||||
@@ -2476,7 +2476,7 @@ cfline (const char *line, struct filed *f)
|
||||
|
||||
/* Decode a symbolic name to a numeric value. */
|
||||
int
|
||||
decode (const char *name, CODE * codetab)
|
||||
decode (const char *name, CODE *codetab)
|
||||
{
|
||||
CODE *c;
|
||||
|
||||
|
||||
@@ -353,7 +353,7 @@ main (int argc, char **argv)
|
||||
}
|
||||
|
||||
void
|
||||
do_try (trace_t * trace, const int hop,
|
||||
do_try (trace_t *trace, const int hop,
|
||||
const int max_hops MAYBE_UNUSED, const int max_tries)
|
||||
{
|
||||
fd_set readset;
|
||||
@@ -466,7 +466,7 @@ get_hostname (struct in_addr *addr)
|
||||
}
|
||||
|
||||
void
|
||||
trace_init (trace_t * t, const struct sockaddr_in to,
|
||||
trace_init (trace_t *t, const struct sockaddr_in to,
|
||||
const enum trace_type type)
|
||||
{
|
||||
int fd;
|
||||
@@ -546,7 +546,7 @@ trace_init (trace_t * t, const struct sockaddr_in to,
|
||||
}
|
||||
|
||||
void
|
||||
trace_port (trace_t * t, const unsigned short int port)
|
||||
trace_port (trace_t *t, const unsigned short int port)
|
||||
{
|
||||
assert (t);
|
||||
if (port < IPPORT_RESERVED)
|
||||
@@ -565,7 +565,7 @@ trace_port (trace_t * t, const unsigned short int port)
|
||||
#define CAPTURE_LEN (MAXIPLEN + MAXICMPLEN)
|
||||
|
||||
int
|
||||
trace_read (trace_t * t, int *type, int *code)
|
||||
trace_read (trace_t *t, int *type, int *code)
|
||||
{
|
||||
int len, rc = 0;
|
||||
unsigned char data[CAPTURE_LEN];
|
||||
@@ -667,7 +667,7 @@ trace_read (trace_t * t, int *type, int *code)
|
||||
}
|
||||
|
||||
int
|
||||
trace_write (trace_t * t)
|
||||
trace_write (trace_t *t)
|
||||
{
|
||||
int len;
|
||||
|
||||
@@ -745,19 +745,19 @@ trace_write (trace_t * t)
|
||||
}
|
||||
|
||||
int
|
||||
trace_udp_sock (trace_t * t)
|
||||
trace_udp_sock (trace_t *t)
|
||||
{
|
||||
return (t != NULL ? t->udpfd : -1);
|
||||
}
|
||||
|
||||
int
|
||||
trace_icmp_sock (trace_t * t)
|
||||
trace_icmp_sock (trace_t *t)
|
||||
{
|
||||
return (t != NULL ? t->icmpfd : -1);
|
||||
}
|
||||
|
||||
void
|
||||
trace_inc_ttl (trace_t * t)
|
||||
trace_inc_ttl (trace_t *t)
|
||||
{
|
||||
int fd;
|
||||
const int *ttlp;
|
||||
@@ -772,7 +772,7 @@ trace_inc_ttl (trace_t * t)
|
||||
}
|
||||
|
||||
void
|
||||
trace_inc_port (trace_t * t)
|
||||
trace_inc_port (trace_t *t)
|
||||
{
|
||||
assert (t);
|
||||
if (t->type == TRACE_UDP)
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
* of time
|
||||
*/
|
||||
int
|
||||
ctl_transact (struct in_addr target, CTL_MSG msg, int type, CTL_RESPONSE * rp)
|
||||
ctl_transact (struct in_addr target, CTL_MSG msg, int type, CTL_RESPONSE *rp)
|
||||
{
|
||||
int nready = 0, cc;
|
||||
fd_set read_mask, ctl_mask;
|
||||
|
||||
@@ -76,7 +76,7 @@ max (int a, int b)
|
||||
* Read the character at the indicated position in win
|
||||
*/
|
||||
static int
|
||||
readwin (WINDOW * win, int line, int col)
|
||||
readwin (WINDOW *win, int line, int col)
|
||||
{
|
||||
int oldline, oldcol;
|
||||
register int c;
|
||||
@@ -93,7 +93,7 @@ readwin (WINDOW * win, int line, int col)
|
||||
* so that the current position is obvious
|
||||
*/
|
||||
static void
|
||||
xscroll (register xwin_t * win, int flag)
|
||||
xscroll (register xwin_t *win, int flag)
|
||||
{
|
||||
if (flag == -1)
|
||||
{
|
||||
@@ -116,7 +116,7 @@ xscroll (register xwin_t * win, int flag)
|
||||
* characters while we are at it.
|
||||
*/
|
||||
int
|
||||
display (register xwin_t * win, register char *text, int size)
|
||||
display (register xwin_t *win, register char *text, int size)
|
||||
{
|
||||
register int i;
|
||||
unsigned char cch;
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
* Look for an invitation on 'machine'
|
||||
*/
|
||||
static int
|
||||
look_for_invite (CTL_RESPONSE * rp)
|
||||
look_for_invite (CTL_RESPONSE *rp)
|
||||
{
|
||||
current_state = "Checking for invitation on caller's machine";
|
||||
ctl_transact (his_machine_addr, msg, LOOK_UP, rp);
|
||||
|
||||
@@ -338,7 +338,7 @@ open_users_acl (char *name)
|
||||
}
|
||||
|
||||
static void
|
||||
netdef_free (netdef_t * netdef)
|
||||
netdef_free (netdef_t *netdef)
|
||||
{
|
||||
netdef_t *next;
|
||||
|
||||
@@ -351,7 +351,7 @@ netdef_free (netdef_t * netdef)
|
||||
}
|
||||
|
||||
static void
|
||||
acl_free (acl_t * acl)
|
||||
acl_free (acl_t *acl)
|
||||
{
|
||||
acl_t *next;
|
||||
|
||||
@@ -366,7 +366,7 @@ acl_free (acl_t * acl)
|
||||
}
|
||||
|
||||
static void
|
||||
discard_acl (acl_t * mark)
|
||||
discard_acl (acl_t *mark)
|
||||
{
|
||||
if (mark)
|
||||
{
|
||||
@@ -379,7 +379,7 @@ discard_acl (acl_t * mark)
|
||||
}
|
||||
|
||||
int
|
||||
acl_match (CTL_MSG * msg, struct sockaddr_in *sa_in)
|
||||
acl_match (CTL_MSG *msg, struct sockaddr_in *sa_in)
|
||||
{
|
||||
acl_t *acl, *mark;
|
||||
in_addr_t ip;
|
||||
|
||||
@@ -39,13 +39,13 @@ typedef struct
|
||||
} LINE;
|
||||
|
||||
static void
|
||||
init_line (LINE * lp)
|
||||
init_line (LINE *lp)
|
||||
{
|
||||
memset (lp, 0, sizeof *lp);
|
||||
}
|
||||
|
||||
static void
|
||||
format_line (LINE * lp, const char *fmt, ...)
|
||||
format_line (LINE *lp, const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
int i = lp->ind;
|
||||
@@ -60,7 +60,7 @@ format_line (LINE * lp, const char *fmt, ...)
|
||||
}
|
||||
|
||||
static char *
|
||||
finish_line (LINE * lp)
|
||||
finish_line (LINE *lp)
|
||||
{
|
||||
int i;
|
||||
char *p;
|
||||
@@ -86,7 +86,7 @@ finish_line (LINE * lp)
|
||||
}
|
||||
|
||||
static int
|
||||
print_mesg (char *tty, CTL_MSG * request, char *remote_machine)
|
||||
print_mesg (char *tty, CTL_MSG *request, char *remote_machine)
|
||||
{
|
||||
time_t t;
|
||||
LINE ln;
|
||||
@@ -123,7 +123,7 @@ print_mesg (char *tty, CTL_MSG * request, char *remote_machine)
|
||||
/* See if the user is accepting messages. If so, announce that
|
||||
a talk is requested. */
|
||||
int
|
||||
announce (CTL_MSG * request, char *remote_machine)
|
||||
announce (CTL_MSG *request, char *remote_machine)
|
||||
{
|
||||
char *ttypath;
|
||||
int len;
|
||||
|
||||
@@ -58,7 +58,7 @@ _xlat_num (int num, const char *array[], int size)
|
||||
}
|
||||
|
||||
int
|
||||
print_request (const char *cp, CTL_MSG * mp)
|
||||
print_request (const char *cp, CTL_MSG *mp)
|
||||
{
|
||||
syslog (LOG_DEBUG, "%s: %s: id %d, l_user %s, r_user %s, r_tty %s",
|
||||
cp, _xlat_num (mp->type, message_types, NITEMS (message_types)),
|
||||
@@ -67,7 +67,7 @@ print_request (const char *cp, CTL_MSG * mp)
|
||||
}
|
||||
|
||||
int
|
||||
print_response (const char *cp, CTL_RESPONSE * rp)
|
||||
print_response (const char *cp, CTL_RESPONSE *rp)
|
||||
{
|
||||
syslog (LOG_DEBUG, "%s: %s: %s, id %d",
|
||||
cp,
|
||||
|
||||
@@ -25,7 +25,7 @@ int find_user (char *name, char *tty);
|
||||
void do_announce (CTL_MSG * mp, CTL_RESPONSE * rp);
|
||||
|
||||
int
|
||||
process_request (CTL_MSG * msg, struct sockaddr_in *sa_in, CTL_RESPONSE * rp)
|
||||
process_request (CTL_MSG *msg, struct sockaddr_in *sa_in, CTL_RESPONSE *rp)
|
||||
{
|
||||
CTL_MSG *ptr;
|
||||
|
||||
@@ -146,7 +146,7 @@ process_request (CTL_MSG * msg, struct sockaddr_in *sa_in, CTL_RESPONSE * rp)
|
||||
}
|
||||
|
||||
void
|
||||
do_announce (CTL_MSG * mp, CTL_RESPONSE * rp)
|
||||
do_announce (CTL_MSG *mp, CTL_RESPONSE *rp)
|
||||
{
|
||||
struct hostent *hp;
|
||||
CTL_MSG *ptr;
|
||||
|
||||
@@ -33,7 +33,7 @@ struct request_table
|
||||
static table_t *table;
|
||||
|
||||
static void
|
||||
table_delete (table_t * ptr)
|
||||
table_delete (table_t *ptr)
|
||||
{
|
||||
table_t *t;
|
||||
|
||||
@@ -51,7 +51,7 @@ table_delete (table_t * ptr)
|
||||
Evil) */
|
||||
|
||||
static CTL_MSG *
|
||||
lookup_request (CTL_MSG * request,
|
||||
lookup_request (CTL_MSG *request,
|
||||
int (*comp) (table_t *, CTL_MSG *, time_t *))
|
||||
{
|
||||
table_t *ptr;
|
||||
@@ -90,7 +90,7 @@ lookup_request (CTL_MSG * request,
|
||||
}
|
||||
|
||||
static int
|
||||
fuzzy_comp (table_t * ptr, CTL_MSG * request, time_t * unused MAYBE_UNUSED)
|
||||
fuzzy_comp (table_t *ptr, CTL_MSG *request, time_t *unused MAYBE_UNUSED)
|
||||
{
|
||||
if (ptr->request.type == LEAVE_INVITE
|
||||
&& strcmp (request->l_name, ptr->request.r_name) == 0
|
||||
@@ -102,13 +102,13 @@ fuzzy_comp (table_t * ptr, CTL_MSG * request, time_t * unused MAYBE_UNUSED)
|
||||
/* Look in the table for an invitation that matches the current
|
||||
request looking for an invitation */
|
||||
CTL_MSG *
|
||||
find_match (CTL_MSG * request)
|
||||
find_match (CTL_MSG *request)
|
||||
{
|
||||
return lookup_request (request, fuzzy_comp);
|
||||
}
|
||||
|
||||
static int
|
||||
exact_comp (table_t * ptr, CTL_MSG * request, time_t * now)
|
||||
exact_comp (table_t *ptr, CTL_MSG *request, time_t *now)
|
||||
{
|
||||
if (request->type == ptr->request.type
|
||||
&& request->pid == ptr->request.pid
|
||||
@@ -125,7 +125,7 @@ exact_comp (table_t * ptr, CTL_MSG * request, time_t * now)
|
||||
one as find_match does */
|
||||
|
||||
CTL_MSG *
|
||||
find_request (CTL_MSG * request)
|
||||
find_request (CTL_MSG *request)
|
||||
{
|
||||
return lookup_request (request, exact_comp);
|
||||
}
|
||||
@@ -146,7 +146,7 @@ new_id (void)
|
||||
}
|
||||
|
||||
int
|
||||
insert_table (CTL_MSG * request, CTL_RESPONSE * response)
|
||||
insert_table (CTL_MSG *request, CTL_RESPONSE *response)
|
||||
{
|
||||
table_t *ptr;
|
||||
|
||||
|
||||
@@ -114,7 +114,7 @@ static unsigned long ring_clock = 0;
|
||||
/* Buffer state transition routines */
|
||||
|
||||
int
|
||||
ring_init (Ring * ring, unsigned char *buffer, int count)
|
||||
ring_init (Ring *ring, unsigned char *buffer, int count)
|
||||
{
|
||||
memset ((char *) ring, 0, sizeof *ring);
|
||||
|
||||
@@ -138,7 +138,7 @@ ring_init (Ring * ring, unsigned char *buffer, int count)
|
||||
*/
|
||||
|
||||
void
|
||||
ring_mark (Ring * ring)
|
||||
ring_mark (Ring *ring)
|
||||
{
|
||||
ring->mark = ring_decrement (ring, ring->supply, 1);
|
||||
}
|
||||
@@ -148,7 +148,7 @@ ring_mark (Ring * ring)
|
||||
*/
|
||||
|
||||
int
|
||||
ring_at_mark (Ring * ring)
|
||||
ring_at_mark (Ring *ring)
|
||||
{
|
||||
if (ring->mark == ring->consume)
|
||||
{
|
||||
@@ -165,7 +165,7 @@ ring_at_mark (Ring * ring)
|
||||
*/
|
||||
|
||||
void
|
||||
ring_clear_mark (Ring * ring)
|
||||
ring_clear_mark (Ring *ring)
|
||||
{
|
||||
ring->mark = 0;
|
||||
}
|
||||
@@ -174,7 +174,7 @@ ring_clear_mark (Ring * ring)
|
||||
* Add characters from current segment to ring buffer.
|
||||
*/
|
||||
void
|
||||
ring_supplied (Ring * ring, int count)
|
||||
ring_supplied (Ring *ring, int count)
|
||||
{
|
||||
ring->supply = ring_increment (ring, ring->supply, count);
|
||||
ring->supplytime = ++ring_clock;
|
||||
@@ -184,7 +184,7 @@ ring_supplied (Ring * ring, int count)
|
||||
* We have just consumed "c" bytes.
|
||||
*/
|
||||
void
|
||||
ring_consumed (Ring * ring, int count)
|
||||
ring_consumed (Ring *ring, int count)
|
||||
{
|
||||
if (count == 0) /* don't update anything */
|
||||
return;
|
||||
@@ -219,7 +219,7 @@ ring_consumed (Ring * ring, int count)
|
||||
|
||||
/* Number of bytes that may be supplied */
|
||||
int
|
||||
ring_empty_count (Ring * ring)
|
||||
ring_empty_count (Ring *ring)
|
||||
{
|
||||
if (ring_empty (ring))
|
||||
{ /* if empty */
|
||||
@@ -233,7 +233,7 @@ ring_empty_count (Ring * ring)
|
||||
|
||||
/* number of CONSECUTIVE bytes that may be supplied */
|
||||
int
|
||||
ring_empty_consecutive (Ring * ring)
|
||||
ring_empty_consecutive (Ring *ring)
|
||||
{
|
||||
if ((ring->consume < ring->supply) || ring_empty (ring))
|
||||
{
|
||||
@@ -257,7 +257,7 @@ ring_empty_consecutive (Ring * ring)
|
||||
*/
|
||||
|
||||
int
|
||||
ring_full_count (Ring * ring)
|
||||
ring_full_count (Ring *ring)
|
||||
{
|
||||
if ((ring->mark == 0) || (ring->mark == ring->consume))
|
||||
{
|
||||
@@ -281,7 +281,7 @@ ring_full_count (Ring * ring)
|
||||
* However, don't return more than enough to cross over set mark.
|
||||
*/
|
||||
int
|
||||
ring_full_consecutive (Ring * ring)
|
||||
ring_full_consecutive (Ring *ring)
|
||||
{
|
||||
if ((ring->mark == 0) || (ring->mark == ring->consume))
|
||||
{
|
||||
@@ -311,7 +311,7 @@ ring_full_consecutive (Ring * ring)
|
||||
* Move data into the "supply" portion of of the ring buffer.
|
||||
*/
|
||||
void
|
||||
ring_supply_data (Ring * ring, unsigned char *buffer, int count)
|
||||
ring_supply_data (Ring *ring, unsigned char *buffer, int count)
|
||||
{
|
||||
int i;
|
||||
|
||||
@@ -327,7 +327,7 @@ ring_supply_data (Ring * ring, unsigned char *buffer, int count)
|
||||
|
||||
#ifdef ENCRYPTION
|
||||
void
|
||||
ring_encrypt (Ring * ring, void (*encryptor) ())
|
||||
ring_encrypt (Ring *ring, void (*encryptor) ())
|
||||
{
|
||||
unsigned char *s, *c;
|
||||
|
||||
@@ -351,7 +351,7 @@ ring_encrypt (Ring * ring, void (*encryptor) ())
|
||||
}
|
||||
|
||||
void
|
||||
ring_clearto (Ring * ring)
|
||||
ring_clearto (Ring *ring)
|
||||
{
|
||||
if (!ring_empty (ring))
|
||||
ring->clearto = ring->supply;
|
||||
|
||||
@@ -31,7 +31,7 @@ TERMDESC termbuf, termbuf2;
|
||||
#ifdef IOCTL_INTERFACE
|
||||
|
||||
void
|
||||
_term_setattr (int fd, TERMDESC * tp)
|
||||
_term_setattr (int fd, TERMDESC *tp)
|
||||
{
|
||||
ioctl (fd, TIOCSETN, (char *) &tp->sg);
|
||||
ioctl (fd, TIOCSETC, (char *) &tp->tc);
|
||||
@@ -590,7 +590,7 @@ set_termbuf (void)
|
||||
return SLC_DEFAULT;
|
||||
|
||||
int
|
||||
spcset (int func, cc_t * valp, cc_t ** valpp)
|
||||
spcset (int func, cc_t *valp, cc_t **valpp)
|
||||
{
|
||||
switch (func)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user