/*
- * $Id: afppasswd.c,v 1.6 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: afppasswd.c,v 1.7 2001-07-31 19:49:02 srittau Exp $
*
* Copyright 1999 (c) Adrian Sun (asun@u.washington.edu)
* All Rights Reserved. See COPYRIGHT.
int i, err = 0;
extern char *optarg;
- extern int optind, opterr;
+ extern int optind;
flags = ((uid = getuid()) == 0) ? OPT_ISROOT : 0;
/*
- * $Id: getzones.c,v 1.4 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: getzones.c,v 1.5 2001-07-31 19:49:02 srittau Exp $
*/
#ifdef HAVE_CONFIG_H
#endif /* HAVE_NETDB_H */
#include <stdio.h>
#include <string.h>
+#include <stdlib.h>
#include <netatalk/endian.h>
#include <netatalk/at.h>
#include <atalk/atp.h>
/*
- * $Id: nbpunrgstr.c,v 1.4 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: nbpunrgstr.c,v 1.5 2001-07-31 19:49:02 srittau Exp $
*
* Copyright (c) 1990,1991 Regents of The University of Michigan.
* All Rights Reserved.
#include <sys/types.h>
#include <stdio.h>
#include <string.h>
+#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif /* HAVE_UNISTD_H */
/*
- * $Id: pap.c,v 1.6 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: pap.c,v 1.7 2001-07-31 19:49:02 srittau Exp $
*
* Copyright (c) 1990,1994 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
#include <stdio.h>
#include <string.h>
#include <string.h>
+#include <stdlib.h>
#include <errno.h>
#define FUCKED
/*
- * $Id: timeout.c,v 1.3 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: timeout.c,v 1.4 2001-07-31 19:49:37 srittau Exp $
*/
#ifdef HAVE_CONFIG_H
int num;
} sigs[] = {
#ifdef SIGHUP
- "HUP", SIGHUP,
+ { "HUP", SIGHUP },
#endif
#ifdef SIGINT
- "INT", SIGINT,
+ { "INT", SIGINT },
#endif
#ifdef SIGQUIT
- "QUIT", SIGQUIT,
+ { "QUIT", SIGQUIT },
#endif
#ifdef SIGILL
- "ILL", SIGILL,
+ { "ILL", SIGILL },
#endif
#ifdef SIGTRAP
- "TRAP", SIGTRAP,
+ { "TRAP", SIGTRAP },
#endif
#ifdef SIGABRT
- "ABRT", SIGABRT,
+ { "ABRT", SIGABRT },
#endif
#ifdef SIGIOT
- "IOT", SIGIOT,
+ { "IOT", SIGIOT },
#endif
#ifdef SIGEMT
- "EMT", SIGEMT,
+ { "EMT", SIGEMT },
#endif
#ifdef SIGFPE
- "FPE", SIGFPE,
+ { "FPE", SIGFPE },
#endif
#ifdef SIGKILL
- "KILL", SIGKILL,
+ { "KILL", SIGKILL },
#endif
#ifdef SIGBUS
- "BUS", SIGBUS,
+ { "BUS", SIGBUS },
#endif
#ifdef SIGSEGV
- "SEGV", SIGSEGV,
+ { "SEGV", SIGSEGV },
#endif
#ifdef SIGSYS
- "SYS", SIGSYS,
+ { "SYS", SIGSYS },
#endif
#ifdef SIGPIPE
- "PIPE", SIGPIPE,
+ { "PIPE", SIGPIPE },
#endif
#ifdef SIGALRM
- "ALRM", SIGALRM,
+ { "ALRM", SIGALRM },
#endif
#ifdef SIGTERM
- "TERM", SIGTERM,
+ { "TERM", SIGTERM },
#endif
#ifdef SIGURG
- "URG", SIGURG,
+ { "URG", SIGURG },
#endif
#ifdef SIGSTOP
- "STOP", SIGSTOP,
+ { "STOP", SIGSTOP },
#endif
#ifdef SIGTSTP
- "TSTP", SIGTSTP,
+ { "TSTP", SIGTSTP },
#endif
#ifdef SIGCONT
- "CONT", SIGCONT,
+ { "CONT", SIGCONT },
#endif
#ifdef SIGCHLD
- "CHLD", SIGCHLD,
+ { "CHLD", SIGCHLD },
#endif
#ifdef SIGCLD
- "CLD", SIGCLD,
+ { "CLD", SIGCLD },
#endif
#ifdef SIGTTIN
- "TTIN", SIGTTIN,
+ { "TTIN", SIGTTIN },
#endif
#ifdef SIGTTOU
- "TTOU", SIGTTOU,
+ { "TTOU", SIGTTOU },
#endif
#ifdef SIGIO
- "IO", SIGIO,
+ { "IO", SIGIO },
#endif
#ifdef SIGXCPU
- "XCPU", SIGXCPU,
+ { "XCPU", SIGXCPU },
#endif
#ifdef SIGXFSZ
- "XFSZ", SIGXFSZ,
+ { "XFSZ", SIGXFSZ },
#endif
#ifdef SIGVTALRM
- "VTALRM", SIGVTALRM,
+ { "VTALRM", SIGVTALRM },
#endif
#ifdef SIGPROF
- "PROF", SIGPROF,
+ { "PROF", SIGPROF },
#endif
#ifdef SIGWINCH
- "WINCH", SIGWINCH,
+ { "WINCH", SIGWINCH },
#endif
#ifdef SIGINFO
- "INFO", SIGINFO,
+ { "INFO", SIGINFO },
#endif
#ifdef SIGUSR1
- "USR1", SIGUSR1,
+ { "USR1", SIGUSR1 },
#endif
#ifdef SIGUSR2
- "USR2", SIGUSR2,
+ { "USR2", SIGUSR2 },
#endif
#ifdef SIGPWR
- "PWR", SIGPWR,
+ { "PWR", SIGPWR },
#endif
- 0, 0
+ { 0, 0 }
};
void
/*
- * $Id: afp_asp.c,v 1.5 2001-06-20 18:33:04 rufustfirefly Exp $
+ * $Id: afp_asp.c,v 1.6 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1997 Adrian Sun (asun@zoology.washington.edu)
* Copyright (c) 1990,1993 Regents of The University of Michigan.
}
writtenfork = NULL;
}
-#endif AFS
+#endif /* AFS */
func = (u_char) asp->commands[0];
if ( obj->options.flags & OPTION_DEBUG ) {
printf( "command: %d\n", func );
/*
- * $Id: afp_options.c,v 1.7 2001-06-20 18:33:04 rufustfirefly Exp $
+ * $Id: afp_options.c,v 1.8 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1997 Adrian Sun (asun@zoology.washington.edu)
* Copyright (c) 1990,1993 Regents of The University of Michigan.
options->configfile = _PATH_AFPDCONF;
options->nlspath = _PATH_AFPDNLSPATH;
options->uampath = _PATH_AFPDUAMPATH;
- options->uamlist = "uams_guest.so,uams_clrtxt.so,uams_dhx.so";
+ options->uamlist = "uams_clrtxt.so,uams_dhx.so";
options->guest = "nobody";
options->loginmesg = "";
options->transports = AFPTRANS_ALL;
/*
- * $Id: auth.c,v 1.16 2001-06-25 15:18:01 rufustfirefly Exp $
+ * $Id: auth.c,v 1.17 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1993 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
uid_t uuid;
#if defined( __svr4__ ) && !defined( NGROUPS )
#define NGROUPS NGROUPS_MAX
-#endif __svr4__ NGROUPS
+#endif /* __svr4__ NGROUPS */
#if defined( sun ) && !defined( __svr4__ ) || defined( ultrix )
int groups[ NGROUPS ];
-#else sun __svr4__ ultrix
+#else /* sun __svr4__ ultrix */
#if defined( __svr4__ ) && !defined( NGROUPS )
#define NGROUPS NGROUPS_MAX
-#endif __svr4__ NGROUPS
+#endif /* __svr4__ NGROUPS */
gid_t groups[ NGROUPS ];
-#endif sun ultrix
+#endif /* sun ultrix */
int ngroups;
/*
{
#ifdef ADMIN_GRP
int admin = 0;
-#endif ADMIN_GRP
+#endif /* ADMIN_GRP */
/* UAM had syslog control; afpd needs to reassert itself */
openlog( "afpd", LOG_NDELAY|LOG_PID, LOG_DAEMON);
/*
- * $Id: quota.c,v 1.9 2001-06-20 18:33:04 rufustfirefly Exp $
+ * $Id: quota.c,v 1.10 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1993 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
if ( quota( Q_GETDLIM, uid, vol->v_gvs, dq ) != 0 ) {
return( AFPERR_PARAM );
}
-#else ultrix
+#else /* ultrix */
#ifndef USRQUOTA
#define USRQUOTA 0
/*
- * $Id: test_parse_mtab.c,v 1.2 2001-06-10 20:15:00 srittau Exp $
+ * $Id: test_parse_mtab.c,v 1.3 2001-07-31 19:50:14 srittau Exp $
* test driver for the afpd_mtab_parse fn. -- rgr, 9-Apr-01.
*/
#include <stdio.h>
#include <errno.h>
#include <string.h>
+#include <stdlib.h>
#ifdef HAVE_SYS_STAT_H
#include <sys/stat.h>
/*
- * $Id: unix.c,v 1.18 2001-06-06 19:04:25 rufustfirefly Exp $
+ * $Id: unix.c,v 1.19 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1993 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
#ifdef ultrix
*bfree = (VolSpace) sfs.fd_req.bfreen;
*bsize = 1024;
-#else
+#else /* !ultrix */
*bfree = (VolSpace) sfs.f_bavail;
*bsize = sfs.f_frsize;
-#endif ultrix
+#endif /* ultrix */
if ( *bfree > maxVolSpace / *bsize ) {
*bfree = maxVolSpace;
#ifdef ultrix
*btotal = (VolSpace)
( sfs.fd_req.btot - ( sfs.fd_req.bfree - sfs.fd_req.bfreen ));
-#else ultrix
+#else /* !ultrix */
*btotal = (VolSpace)
( sfs.f_blocks - ( sfs.f_bfree - sfs.f_bavail ));
-#endif ultrix
+#endif /* ultrix */
// see similar block above comments
if ( *btotal > maxVolSpace / *bsize ) {
/*
- * $Id: interface.h,v 1.2 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: interface.h,v 1.3 2001-07-31 19:50:14 srittau Exp $
* Copyright (c) 1990,1992 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
*/
#ifdef linux
#define LOOPIFACE "lo"
-#else linux
+#else /* !linux */
#define LOOPIFACE "lo0"
-#endif linux
+#endif /* linux */
extern struct interface *interfaces;
extern struct interface *ciface;
/*
- * $Id: multicast.c,v 1.5 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: multicast.c,v 1.6 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1993 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
}
for ( i = 0; i < zt->zt_len; i++ ) {
- uname[ i ] = diatoupper(zt->zt_name[ i ]);
+ uname[ i ] = diatoupper((int) zt->zt_name[ i ]);
}
cksum = atalk_cksum( uname, zt->zt_len );
#define elements(a) (sizeof(a)/sizeof((a)[0]))
/*
- * $Id: main.c,v 1.7 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: main.c,v 1.8 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1995 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
char **av;
{
extern char *optarg;
- extern int optind;
ATP atp;
struct atp_block atpb;
/*
- * $Id: printcap.c,v 1.4 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: printcap.c,v 1.5 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1994 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
#include <ctype.h>
#include <stdio.h>
#include <string.h>
-#ifndef HAVE_UNISTD_H
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif /* HAVE_UNISTD_H */
#include <sys/types.h>
/*
- * $Id: queries.c,v 1.7 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: queries.c,v 1.8 2001-07-31 19:50:14 srittau Exp $
*
* Copyright (c) 1990,1994 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
#ifdef KRB
{ "%%Login: UMICHKerberosIV", 0, cq_k4login, 0 },
{ "%%?BeginUAMethodsQuery", "%%?EndUAMethodsQuery:", cq_uameth, C_FULL },
-#endif KRB
+#endif /* KRB */
{ "%UMICHListQueue", 0, cq_listq, C_FULL },
{ "%UMICHDeleteJob", 0, cq_rmjob, 0 },
{ "%%?BeginQuery: RBILogin ", "%%?EndQuery", cq_rbilogin, 0 },
/*
- * $Id: adouble.h,v 1.6 2001-06-11 17:27:28 rufustfirefly Exp $
+ * $Id: adouble.h,v 1.7 2001-07-31 19:51:12 srittau Exp $
* Copyright (c) 1990,1991 Regents of The University of Michigan.
* All Rights Reserved.
*
#define AD_DATASZ_MAX 1024
#if AD_VERSION == AD_VERSION1
#define AD_DATASZ AD_DATASZ1 /* hold enough for the entries */
-#else if AD_VERSION == AD_VERSION2
+#elif AD_VERSION == AD_VERSION2
#define AD_DATASZ AD_DATASZ2
#endif
#if BYTE_ORDER == BIG_ENDIAN
unsigned nh_op : 4,
nh_cnt : 4,
-#else BYTE_ORDER
+#else /* BYTE_ORDER != BIG_ENDIAN */
unsigned nh_cnt : 4,
nh_op : 4,
-#endif BYTE_ORDER
+#endif /* BYTE_ORDER */
nh_id : 8;
};
#define _PATH_PAPDPRINTCAP "/etc/printcap"
#ifdef ultrix
#define _PATH_PAPDSPOOLDIR "/usr/spool/lpd"
-#else ultrix
+#else /* !ultrix */
#define _PATH_PAPDSPOOLDIR "/var/spool/lpd"
-#endif ultrix
+#endif /* ultrix */
#ifdef BSD4_4
#define _PATH_DEVPRINTER "/var/run/printer"
-#else BSD4_4
+#else /* !BSD4_4 */
#define _PATH_DEVPRINTER "/dev/printer"
-#endif BSD4_4
+#endif /* BSD4_4 */
/*
* atalkd paths
/*
- * $Id: ad_open.c,v 1.8 2001-06-29 14:14:46 rufustfirefly Exp $
+ * $Id: ad_open.c,v 1.9 2001-07-31 19:52:25 srittau Exp $
*
* Copyright (c) 1999 Adrian Sun (asun@u.washington.edu)
* Copyright (c) 1990,1991 Regents of The University of Michigan.
{ADEID_RFORK, ADEDOFF_RFORK_V1, ADEDLEN_INIT},
{0, 0, 0}
};
-#else if AD_VERSION == AD_VERSION2
+#else /* AD_VERSION == AD_VERSION2 */
static const struct entry entry_order[] = {
{ADEID_NAME, ADEDOFF_NAME_V2, ADEDLEN_INIT},
{ADEID_COMMENT, ADEDOFF_COMMENT_V2, ADEDLEN_INIT},
ifrsize = sizeof(ifr->ifr_name) +
(ifr->ifr_addr.sa_len > sizeof(struct sockaddr)
? ifr->ifr_addr.sa_len : sizeof(struct sockaddr));
-#else BSD4_4
+#else /* !BSD4_4 */
ifrsize = sizeof( struct ifreq );
-#endif BSD4_4
+#endif /* BSD4_4 */
nextifr = (struct ifreq *)((caddr_t)ifr + ifrsize );
/* just bail if there's a problem */