svn commit: r209359 - head/usr.sbin/sysinstall

Randi Harper randi at FreeBSD.org
Sun Jun 20 04:14:50 UTC 2010


Author: randi
Date: Sun Jun 20 04:14:49 2010
New Revision: 209359
URL: http://svn.freebsd.org/changeset/base/209359

Log:
  Clean up item_add and remove -fno-strict-aliasing from CFLAGS.  Note that
  the "aux" value in libdialog is really an opaque pointer, but libdialog
  stores it as a long for historical reasons.
  
  Approved by:	cperciva (mentor)

Modified:
  head/usr.sbin/sysinstall/Makefile
  head/usr.sbin/sysinstall/index.c
  head/usr.sbin/sysinstall/misc.c
  head/usr.sbin/sysinstall/sysinstall.h

Modified: head/usr.sbin/sysinstall/Makefile
==============================================================================
--- head/usr.sbin/sysinstall/Makefile	Sun Jun 20 00:34:06 2010	(r209358)
+++ head/usr.sbin/sysinstall/Makefile	Sun Jun 20 04:14:49 2010	(r209359)
@@ -14,7 +14,7 @@ SRCS=	anonFTP.c cdrom.c command.c config
 	system.c tcpip.c termcap.c ttys.c ufs.c usb.c user.c \
 	variable.c ${_wizard} keymap.h countries.h
 
-CFLAGS+= -DUSE_GZIP=1 -fno-strict-aliasing
+CFLAGS+= -DUSE_GZIP=1 
 .if ${MACHINE} == "pc98"
 CFLAGS+= -DPC98
 .endif

Modified: head/usr.sbin/sysinstall/index.c
==============================================================================
--- head/usr.sbin/sysinstall/index.c	Sun Jun 20 00:34:06 2010	(r209358)
+++ head/usr.sbin/sysinstall/index.c	Sun Jun 20 04:14:49 2010	(r209359)
@@ -650,8 +650,8 @@ index_menu(PkgNodePtr root, PkgNodePtr t
 		SAFE_STRCPY(buf, kp->desc);
 	    if (strlen(buf) > (_MAX_DESC - maxname))
 		buf[_MAX_DESC - maxname] = '\0';
-	    nitems = item_add(nitems, kp->name, (char *)buf, pkg_checked, 
-			      pkg_fire, pkg_selected, kp, (int *)(&lists), 
+	    nitems = item_add(nitems, kp->name, buf, pkg_checked, 
+			      pkg_fire, pkg_selected, kp, &lists, 
 			      &curr, &max);
 	    ++n;
 	    kp = kp->next;

Modified: head/usr.sbin/sysinstall/misc.c
==============================================================================
--- head/usr.sbin/sysinstall/misc.c	Sun Jun 20 00:34:06 2010	(r209358)
+++ head/usr.sbin/sysinstall/misc.c	Sun Jun 20 04:14:49 2010	(r209359)
@@ -238,7 +238,7 @@ item_add(dialogMenuItem *list, char *pro
 	 int (*checked)(dialogMenuItem *self),
 	 int (*fire)(dialogMenuItem *self),
 	 void (*selected)(dialogMenuItem *self, int is_selected),
-	 void *data, int *aux, int *curr, int *max)
+	 void *data, void *aux, int *curr, int *max)
 {
     dialogMenuItem *d;
 

Modified: head/usr.sbin/sysinstall/sysinstall.h
==============================================================================
--- head/usr.sbin/sysinstall/sysinstall.h	Sun Jun 20 00:34:06 2010	(r209358)
+++ head/usr.sbin/sysinstall/sysinstall.h	Sun Jun 20 04:14:49 2010	(r209359)
@@ -755,7 +755,7 @@ extern dialogMenuItem *item_add(dialogMe
 				int (*checked)(dialogMenuItem *self),
 				int (*fire)(dialogMenuItem *self),
 				void (*selected)(dialogMenuItem *self, int is_selected),
-				void *data, int *aux, int *curr, int *max);
+				void *data, void *aux, int *curr, int *max);
 extern void	items_free(dialogMenuItem *list, int *curr, int *max);
 extern int	Mkdir(char *);
 extern int	Mkdir_command(char *key, void *data);


More information about the svn-src-all mailing list