2015-10-20 Joseph Myers <joseph@codesourcery.com>
+ * crypt/crypt.c (_ufc_doit_r): Convert to prototype-style function
+ definition.
+ (_ufc_doit_r): Likewise.
+ * crypt/crypt_util.c (_ufc_copymem): Likewise.
+ (_ufc_output_conversion_r): Likewise.
+ * inet/inet_mkadr.c (__inet_makeaddr): Likewise.
+ * inet/rcmd.c (rcmd_af): Likewise.
+ (rcmd): Likewise.
+ (ruserok_af): Likewise.
+ (ruserok): Likewise.
+ (ruserok2_sa): Likewise.
+ (ruserok_sa): Likewise.
+ (iruserok_af): Likewise.
+ (iruserok): Likewise.
+ (__ivaliduser): Likewise.
+ (__validuser2_sa): Likewise.
+ * inet/rexec.c (rexec_af): Likewise.
+ (rexec): Likewise.
+ * inet/ruserpass.c (ruserpass): Likewise.
+ * locale/programs/xmalloc.c (xcalloc): Likewise.
+ * manual/examples/timeval_subtract.c (timeval_subtract): Likewise.
+ * math/w_drem.c (__drem): Likewise.
+ * math/w_dremf.c (__dremf): Likewise.
+ * math/w_dreml.c (__dreml): Likewise.
+ * misc/daemon.c (daemon): Likewise.
+ * resolv/res_debug.c (p_fqnname): Likewise.
+ * stdlib/div.c (div): Likewise.
+ * string/memcmp.c (memcmp_bytes): Likewise.
+ * sunrpc/pmap_rmt.c (pmap_rmtcall): Likewise.
+ * sunrpc/svc_udp.c (svcudp_bufcreate): Likewise.
+
* crypt/cert.c (main): Convert to prototype-style function
definition.
* io/pipe.c (__pipe): Likewise.
#define SBA(sb, v) (*(long32*)((char*)(sb)+(v)))
void
-_ufc_doit_r(itr, __data, res)
- ufc_long itr, *res;
- struct crypt_data * __restrict __data;
+_ufc_doit_r (ufc_long itr, struct crypt_data * __restrict __data,
+ ufc_long *res)
{
int i;
long32 s, *k;
#define SBA(sb, v) (*(long64*)((char*)(sb)+(v)))
void
-_ufc_doit_r(itr, __data, res)
- ufc_long itr, *res;
- struct crypt_data * __restrict __data;
+_ufc_doit_r (ufc_long itr, struct crypt_data * __restrict __data,
+ ufc_long *res)
{
int i;
long64 l, r, s, *k;
}
void
-_ufc_copymem(from, to, cnt)
- char *from, *to;
- int cnt;
+_ufc_copymem (char *from, char *to, int cnt)
{
while(cnt--)
*to++ = *from++;
*/
void
-_ufc_output_conversion_r(v1, v2, salt, __data)
- ufc_long v1, v2;
- const char *salt;
- struct crypt_data * __restrict __data;
+_ufc_output_conversion_r (ufc_long v1, ufc_long v2, const char *salt,
+ struct crypt_data * __restrict __data)
{
int i, s, shf;
* building addresses stored in the ifnet structure.
*/
struct in_addr
-__inet_makeaddr(net, host)
- in_addr_t net, host;
+__inet_makeaddr (in_addr_t net, in_addr_t host)
{
struct in_addr in;
libc_freeres_ptr(static char *ahostbuf);
int
-rcmd_af(ahost, rport, locuser, remuser, cmd, fd2p, af)
- char **ahost;
- u_short rport;
- const char *locuser, *remuser, *cmd;
- int *fd2p;
- sa_family_t af;
+rcmd_af (char **ahost, u_short rport, const char *locuser, const char *remuser,
+ const char *cmd, int *fd2p, sa_family_t af)
{
char paddr[INET6_ADDRSTRLEN];
struct addrinfo hints, *res, *ai;
libc_hidden_def (rcmd_af)
int
-rcmd(ahost, rport, locuser, remuser, cmd, fd2p)
- char **ahost;
- u_short rport;
- const char *locuser, *remuser, *cmd;
- int *fd2p;
+rcmd (char **ahost, u_short rport, const char *locuser, const char *remuser,
+ const char *cmd, int *fd2p)
{
return rcmd_af (ahost, rport, locuser, remuser, cmd, fd2p, AF_INET);
}
char *__rcmd_errstr;
int
-ruserok_af(rhost, superuser, ruser, luser, af)
- const char *rhost, *ruser, *luser;
- int superuser;
- sa_family_t af;
+ruserok_af (const char *rhost, int superuser, const char *ruser,
+ const char *luser, sa_family_t af)
{
struct addrinfo hints, *res, *res0;
int gai;
libc_hidden_def (ruserok_af)
int
-ruserok(rhost, superuser, ruser, luser)
- const char *rhost, *ruser, *luser;
- int superuser;
+ruserok (const char *rhost, int superuser, const char *ruser,
+ const char *luser)
{
return ruserok_af(rhost, superuser, ruser, luser, AF_INET);
}
* Returns 0 if ok, -1 if not ok.
*/
static int
-ruserok2_sa (ra, ralen, superuser, ruser, luser, rhost)
- struct sockaddr *ra;
- size_t ralen;
- int superuser;
- const char *ruser, *luser, *rhost;
+ruserok2_sa (struct sockaddr *ra, size_t ralen, int superuser,
+ const char *ruser, const char *luser, const char *rhost)
{
FILE *hostf = NULL;
int isbad = -1;
* ruserok_sa() is now discussed on ipng, so
* currently disabled for external use
*/
-static int ruserok_sa(ra, ralen, superuser, ruser, luser)
- struct sockaddr *ra;
- size_t ralen;
- int superuser;
- const char *ruser, *luser;
+static int
+ruserok_sa (struct sockaddr *ra, size_t ralen, int superuser,
+ const char *ruser, const char *luser)
{
return ruserok2_sa(ra, ralen, superuser, ruser, luser, "-");
}
/* This is the exported version. */
int
-iruserok_af (raddr, superuser, ruser, luser, af)
- const void *raddr;
- int superuser;
- const char *ruser, *luser;
- sa_family_t af;
+iruserok_af (const void *raddr, int superuser, const char *ruser,
+ const char *luser, sa_family_t af)
{
union {
struct sockaddr generic;
libc_hidden_def (iruserok_af)
int
-iruserok (raddr, superuser, ruser, luser)
- u_int32_t raddr;
- int superuser;
- const char *ruser, *luser;
+iruserok (u_int32_t raddr, int superuser, const char *ruser, const char *luser)
{
return iruserok_af (&raddr, superuser, ruser, luser, AF_INET);
}
* Returns 0 if ok, -1 if not ok.
*/
int
-__ivaliduser(hostf, raddr, luser, ruser)
- FILE *hostf;
- u_int32_t raddr;
- const char *luser, *ruser;
+__ivaliduser (FILE *hostf, u_int32_t raddr, const char *luser,
+ const char *ruser)
{
struct sockaddr_in ra;
memset(&ra, '\0', sizeof(ra));
* Returns 0 if positive match, -1 if _not_ ok.
*/
static int
-__validuser2_sa(hostf, ra, ralen, luser, ruser, rhost)
- FILE *hostf;
- struct sockaddr *ra;
- size_t ralen;
- const char *luser, *ruser, *rhost;
+__validuser2_sa (FILE *hostf, struct sockaddr *ra, size_t ralen,
+ const char *luser, const char *ruser, const char *rhost)
{
const char *user;
char *p;
libc_freeres_ptr (static char *ahostbuf);
int
-rexec_af(ahost, rport, name, pass, cmd, fd2p, af)
- char **ahost;
- int rport;
- const char *name, *pass, *cmd;
- int *fd2p;
- sa_family_t af;
+rexec_af (char **ahost, int rport, const char *name, const char *pass,
+ const char *cmd, int *fd2p, sa_family_t af)
{
struct sockaddr_storage from;
struct addrinfo hints, *res0;
libc_hidden_def (rexec_af)
int
-rexec(ahost, rport, name, pass, cmd, fd2p)
- char **ahost;
- int rport;
- const char *name, *pass, *cmd;
- int *fd2p;
+rexec (char **ahost, int rport, const char *name, const char *pass,
+ const char *cmd, int *fd2p)
{
return rexec_af(ahost, rport, name, pass, cmd, fd2p, AF_INET);
}
int
-ruserpass(host, aname, apass)
- const char *host, **aname, **apass;
+ruserpass (const char *host, const char **aname, const char **apass)
{
char *hdir, *buf, *tmp;
char myname[1024], *mydomain;
/* Allocate memory for N elements of S bytes, with error checking. */
VOID *
-xcalloc (n, s)
- size_t n, s;
+xcalloc (size_t n, size_t s)
{
VOID *p;
Return 1 if the difference is negative, otherwise 0. */
int
-timeval_subtract (result, x, y)
- struct timeval *result, *x, *y;
+timeval_subtract (struct timeval *result, struct timeval *x, struct timeval *y)
{
/* Perform the carry for the later subtraction by updating @var{y}. */
if (x->tv_usec < y->tv_usec) {
#include <math.h>
double
-__drem(x, y)
- double x, y;
+__drem (double x, double y)
{
return __remainder(x, y);
}
#include <math_private.h>
float
-__dremf(x, y)
- float x, y;
+__dremf (float x, float y)
{
return __remainderf(x, y);
}
#include <math.h>
long double
-__dreml(x, y)
- long double x, y;
+__dreml (long double x, long double y)
{
return __remainderl(x, y);
}
#include <not-cancel.h>
int
-daemon(nochdir, noclose)
- int nochdir, noclose;
+daemon (int nochdir, int noclose)
{
int fd;
length supplied). */
const u_char *
-p_fqnname(cp, msg, msglen, name, namelen)
- const u_char *cp, *msg;
- int msglen;
- char *name;
- int namelen;
+p_fqnname (const u_char *cp, const u_char *msg, int msglen, char *name,
+ int namelen)
{
int n, newlen;
/* Return the `div_t' representation of NUMER over DENOM. */
div_t
-div (numer, denom)
- int numer, denom;
+div (int numer, int denom)
{
div_t result;
static int memcmp_bytes (op_t, op_t) __THROW;
static int
-memcmp_bytes (a, b)
- op_t a, b;
+memcmp_bytes (op_t a, op_t b)
{
long int srcp1 = (long int) &a;
long int srcp2 = (long int) &b;
* programs to do a lookup and call in one step.
*/
enum clnt_stat
-pmap_rmtcall (addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout, port_ptr)
- struct sockaddr_in *addr;
- u_long prog, vers, proc;
- xdrproc_t xdrargs, xdrres;
- caddr_t argsp, resp;
- struct timeval tout;
- u_long *port_ptr;
+pmap_rmtcall (struct sockaddr_in *addr, u_long prog, u_long vers, u_long proc,
+ xdrproc_t xdrargs, caddr_t argsp, xdrproc_t xdrres, caddr_t resp,
+ struct timeval tout, u_long *port_ptr)
{
int socket = -1;
CLIENT *client;
* The routines returns NULL if a problem occurred.
*/
SVCXPRT *
-svcudp_bufcreate (sock, sendsz, recvsz)
- int sock;
- u_int sendsz, recvsz;
+svcudp_bufcreate (int sock, u_int sendsz, u_int recvsz)
{
bool_t madesock = FALSE;
SVCXPRT *xprt;