Use explicit cast instead of -Wno-pointer-sign. The site in question is

already marked XXX so there's not much point in whitewashing it.
This commit is contained in:
dholland 2011-08-06 16:34:40 +00:00
parent 3b8c9b3e65
commit f8a6ea099c
2 changed files with 5 additions and 9 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.6 2011/06/20 07:43:59 mrg Exp $
# $NetBSD: Makefile,v 1.7 2011/08/06 16:34:40 dholland Exp $
PROG= dkctl
MAN= dkctl.8
@ -7,7 +7,3 @@ LDADD+= -lutil
DPADD+= ${LIBUTIL}
.include <bsd.prog.mk>
.if defined(HAVE_GCC) || defined(HAVE_PCC)
COPTS.dkctl.c+= -Wno-pointer-sign
.endif

View File

@ -1,4 +1,4 @@
/* $NetBSD: dkctl.c,v 1.18 2009/08/02 18:16:08 spz Exp $ */
/* $NetBSD: dkctl.c,v 1.19 2011/08/06 16:34:40 dholland Exp $ */
/*
* Copyright 2001 Wasabi Systems, Inc.
@ -41,7 +41,7 @@
#include <sys/cdefs.h>
#ifndef lint
__RCSID("$NetBSD: dkctl.c,v 1.18 2009/08/02 18:16:08 spz Exp $");
__RCSID("$NetBSD: dkctl.c,v 1.19 2011/08/06 16:34:40 dholland Exp $");
#endif
@ -550,8 +550,8 @@ disk_addwedge(int argc, char *argv[])
if (argc != 4)
usage();
/* XXX Unicode. */
if (strlcpy(dkw.dkw_wname, argv[0], sizeof(dkw.dkw_wname)) >=
/* XXX Unicode: dkw_wname is supposed to be utf-8 */
if (strlcpy((char *)dkw.dkw_wname, argv[0], sizeof(dkw.dkw_wname)) >=
sizeof(dkw.dkw_wname))
errx(1, "Wedge name too long; max %zd characters",
sizeof(dkw.dkw_wname) - 1);