A.i386-unknown-netbsdelf2.0
A.i386-unknown-openbsd3.6
A.powerpc-apple-darwin7.6.0
+A.powerpc-ibm-aix5.3.0.0
+A.powerpc-ibm-aix5.3.0.0-cc
+2005-02-16 Erez Zadok <ezk@cs.sunysb.edu>
+
+ * amd/get_args.c (get_args): move call to switch_to_logfile()
+ after processing -v, so we don't print "no logfile defined; using
+ stderr" when we're about to print version info and exit anyway.
+
+ * minor new port: powerpc-ibm-aix5.3.0.0.
+
+ * hlfsd/hlfsd.c (main): rewrite code to avoid negative array
+ references.
+
+ * conf/checkmount/checkmount_aix.c: remove extern definition for
+ mntctl(), since AIX 5.3 has it in <sys/vmount.h>.
+
+ * amd/info_union.c (union_reload): rewrite code to avoid negative
+ array references.
+
+ * amd/opts.c (split_opts, expand_op): rewrite code to avoid
+ negative array references.
+
+ * conf/mtab/mtab_aix.c: remove extern definition for mntctl(),
+ since AIX 5.3 has it in <sys/vmount.h>.
+
+ * libamu/xutil.c (real_plog): rewrite code to avoid negative array
+ references.
+
+ * libamu/wire.c (is_network_member): rearrange code slightly to
+ avoid negative array references (AIX 5.3 xlC 7.0 compiler
+ complains about it).
+
2005-01-26 Erez Zadok <ezk@cs.sunysb.edu>
* doc/am-utils.texi (xhost Selector Function): document new
i386-unknown-netbsdelf2.0
mipsel-unknown-linux-rhPS2 (Linux on Sony PlayStation 2)
powerpc-apple-darwin7.6.0
+ powerpc-ibm-aix5.2.0.0
+ powerpc-ibm-aix5.3.0.0
sparc-sun-solaris2.10
sparc64-unknown-linux-deb3.0
x86_64-unknown-linux-rh2.9.5AS
* SUCH DAMAGE.
*
*
- * $Id: get_args.c,v 1.25 2005/01/14 04:50:38 ezk Exp $
+ * $Id: get_args.c,v 1.26 2005/02/17 03:37:42 ezk Exp $
*
*/
# endif /* MNTTAB_FILE_NAME */
#endif /* not MOUNT_TABLE_ON_FILE */
- if (switch_to_logfile(gopt.logfile, orig_umask) != 0)
- plog(XLOG_USER, "Cannot switch logfile");
-
/*
* If the kernel architecture was not specified
* then use the machine architecture.
exit(0);
}
+ if (switch_to_logfile(gopt.logfile, orig_umask) != 0)
+ plog(XLOG_USER, "Cannot switch logfile");
+
return;
}
* SUCH DAMAGE.
*
*
- * $Id: info_union.c,v 1.10 2005/01/03 20:56:45 ezk Exp $
+ * $Id: info_union.c,v 1.11 2005/02/17 03:37:42 ezk Exp $
*
*/
* Add wildcard entry
*/
{
- char *val = xmalloc(strlen(dir[-1]) + 5);
+ char *val = xmalloc(strlen(*(dir-1)) + 5);
- sprintf(val, "fs:=%s", dir[-1]);
+ sprintf(val, "fs:=%s", *(dir-1));
(*fn) (m, strdup("*"), val);
}
XFREE(mapd);
* SUCH DAMAGE.
*
*
- * $Id: opts.c,v 1.34 2005/01/26 06:16:30 ezk Exp $
+ * $Id: opts.c,v 1.35 2005/02/17 03:37:42 ezk Exp $
*
*/
if (!eq)
continue;
- if (eq[-1] == '!' ||
+ if (*(eq-1) == '!' ||
eq[1] == '=' ||
eq[1] == '!') { /* != or == or =! */
continue; /* we don't care about selectors */
}
- if (eq[-1] == ':') { /* := */
- eq[-1] = '\0';
+ if (*(eq-1) == ':') { /* := */
+ *(eq-1) = '\0';
} else {
/* old style assignment */
eq[0] = '\0';
* == is SelEQ
* =, := is VarAss
*/
- if (eq[-1] == '!') { /* != */
+ if (*(eq-1) == '!') { /* != */
vs_opt = SelNE;
- eq[-1] = '\0';
+ *(eq-1) = '\0';
opt = eq + 1;
- } else if (eq[-1] == ':') { /* := */
+ } else if (*(eq-1) == ':') { /* := */
continue;
} else if (eq[1] == '=') { /* == */
vs_opt = SelEQ;
* == is SelEQ
* := is VarAss
*/
- if (eq[-1] == '!') { /* != */
+ if (*(eq-1) == '!') { /* != */
vs_opt = SelNE;
- } else if (eq[-1] == ':') { /* := */
+ } else if (*(eq-1) == ':') { /* := */
vs_opt = VarAss;
} else if (eq[1] == '=') { /* == */
vs_opt = SelEQ;
todo = E_File;
cp++;
--len;
- } else if (br_p[-1] == '/') {
+ } else if (*(br_p-1) == '/') {
/*
* Take all but the last component
*/
todo = E_Domain;
cp++;
--len;
- } else if (br_p[-1] == '.') {
+ } else if (*(br_p-1) == '.') {
/*
* Take host name
*/
* SUCH DAMAGE.
*
*
- * $Id: checkmount_aix.c,v 1.10 2005/01/03 20:56:45 ezk Exp $
+ * $Id: checkmount_aix.c,v 1.11 2005/02/17 03:37:42 ezk Exp $
*
*/
/* external definitions */
extern int is_same_host(char *name1, char *name2, struct in_addr addr2);
+#if 0
+#error no longer needed on AIX 5.3
extern int mntctl(int Command, int Size, char *Buffer);
+#endif
int
* SUCH DAMAGE.
*
*
- * $Id: mtab_aix.c,v 1.12 2005/01/03 20:56:45 ezk Exp $
+ * $Id: mtab_aix.c,v 1.13 2005/02/17 03:37:42 ezk Exp $
*
*/
#include <am_defs.h>
#include <amu.h>
-/* missing external definitions from AIX's headers */
+/*
+ * These were missing external definitions from old AIX's headers. They
+ * appear to be available in <sys/vmount.h> on AIX 5.3, and possibly
+ * earlier. Hence I commented this out.
+ */
+#if 0
extern int mntctl(int cmd, int size, voidp buf);
+#endif
static mntent_t *
* SUCH DAMAGE.
*
*
- * $Id: hlfsd.c,v 1.30 2005/01/13 21:24:12 ezk Exp $
+ * $Id: hlfsd.c,v 1.31 2005/02/17 03:37:42 ezk Exp $
*
* HLFSD was written at Columbia University Computer Science Department, by
* Erez Zadok <ezk@cs.columbia.edu> and Alexander Dupuy <dupuy@cs.columbia.edu>
chmod(alt_spooldir, OPEN_SPOOLMODE);
/* create failsafe link to alternate spool directory */
- slinkname[-1] = '/'; /* unsplit dir_name to include link */
+ *(slinkname-1) = '/'; /* unsplit dir_name to include link */
if (lstat(dir_name, &stmodes) == 0 &&
(stmodes.st_mode & S_IFMT) != S_IFLNK) {
fprintf(stderr, "%s: failsafe %s not a symlink\n",
}
}
- slinkname[-1] = '\0'; /* resplit dir_name */
+ *(slinkname-1) = '\0'; /* resplit dir_name */
} /* end of "if (!forcefast) {" */
/*
* SUCH DAMAGE.
*
*
- * $Id: wire.c,v 1.21 2005/01/03 20:56:46 ezk Exp $
+ * $Id: wire.c,v 1.22 2005/02/17 03:37:42 ezk Exp $
*
*/
char *netstr = strdup(net), *maskstr;
u_long netnum, masknum = 0;
maskstr = strchr(netstr, '/');
+ maskstr[0] = '\0'; /* null terminate netstr */
maskstr++;
- maskstr[-1] = '\0'; /* null terminate netstr */
if (*maskstr == '\0') /* if empty string, make it NULL */
maskstr = NULL;
/* check if netmask uses a dotted-quad or bit-length, or not defined at all */
* SUCH DAMAGE.
*
*
- * $Id: xutil.c,v 1.33 2005/01/03 20:56:46 ezk Exp $
+ * $Id: xutil.c,v 1.34 2005/02/17 03:37:42 ezk Exp $
*
*/
#endif /* not HAVE_VSNPRINTF */
ptr += strlen(ptr);
- if (ptr[-1] == '\n')
+ if (*(ptr-1) == '\n')
*--ptr = '\0';
#ifdef HAVE_SYSLOG
# turn on additional headers
ac_cv_os_cflags="-D_XOPEN_EXTENDED_SOURCE"
;;
+ aix5.3* )
+ # avoid circular dependencies in yp headers, and more
+ ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE -D_USE_IRS -D_MSGQSUPPORT"
+ ;;
aix* )
# avoid circular dependencies in yp headers
ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE -D_USE_IRS"