NetBSD Problem Report #45989
From martin@duskware.de Sun Feb 12 01:26:29 2012
Return-Path: <martin@duskware.de>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
by www.NetBSD.org (Postfix) with ESMTP id 2B2B763E007
for <gnats-bugs@gnats.NetBSD.org>; Sun, 12 Feb 2012 01:26:29 +0000 (UTC)
Message-Id: <20120212012629.2B2B763E007@www.NetBSD.org>
Date: Sun, 12 Feb 2012 01:26:29 +0000 (UTC)
From: martin@NetBSD.org
Reply-To: martin@NetBSD.org
To: gnats-bugs@gnats.NetBSD.org
Subject: lint does not use -w on anything != i386 for libc
X-Send-Pr-Version: 3.95
>Number: 45989
>Category: lib
>Synopsis: libc lint invocation does include -w only on i386
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: lib-bug-people
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Sun Feb 12 01:30:01 +0000 2012
>Closed-Date:
>Last-Modified: Sat Mar 17 17:00:03 +0000 2012
>Originator: Martin Husemann
>Release: NetBSD 5.99.60
>Organization:
The NetBSD Foundation, Inc.
>Environment:
System: NetBSD night-owl.duskware.de 5.99.60 NetBSD 5.99.60 (NIGHT-OWL) #50: Sat Jan 28 11:49:36 CET 2012 martin@night-owl.duskware.de:/usr/src/sys/arch/amd64/compile/NIGHT-OWL amd64
Architecture: x86_64
Machine: amd64
>Description:
The src/lib/libc/Makefile.inc has the following gem:
.if ${MACHINE_ARCH} == "i386"
# Set lint to exit on warnings
LINTFLAGS+= -w
.endif
Since most people do not develop on i386 machines any more, this may lead
to missed warnings from lint that later break the build post commit (like
recently with the posix_spawn addition).
We should aim for libc being lintclean on all archs, but as a stopgap, at
least amd64 should be added to the list.
>How-To-Repeat:
code inspection (or watch the autmatic test environment catch you breaking
the build).
>Fix:
Remove the .if, fix the fallout.
>Release-Note:
>Audit-Trail:
From: "Christos Zoulas" <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/45989 CVS commit: src/lib/libc
Date: Tue, 13 Mar 2012 17:13:51 -0400
Module Name: src
Committed By: christos
Date: Tue Mar 13 21:13:49 UTC 2012
Modified Files:
src/lib/libc: Makefile.inc
src/lib/libc/cdb: cdbw.c
src/lib/libc/citrus: citrus_memstream.c
src/lib/libc/compat/db/hash: compat_ndbmdatum.c
src/lib/libc/compat/gen: compat___fts13.c compat___fts30.c
compat___fts31.c
src/lib/libc/compat/sys: compat_getdents.c compat_sigaltstack.c
src/lib/libc/db/btree: bt_open.c bt_overflow.c
src/lib/libc/db/hash: hash.c hash_bigkey.c hash_page.c ndbmdatum.c
src/lib/libc/dlfcn: dlfcn_elf.c
src/lib/libc/gdtoa: gdtoa.c gdtoaimp.h gmisc.c smisc.c strtod.c
strtodg.c
src/lib/libc/gen: dehumanize_number.c disklabel.c extattr.c fstab.c
fts.c getcap.c getcwd.c getdevmajor.c getgrent.c getloadavg.c
getusershell.c humanize_number.c initdir.c psignal.c pw_scan.c
scandir.c sysctl.c sysctlgetmibinfo.c sysctlnametomib.c syslog.c
time.c unvis.c utmpx.c
src/lib/libc/gmon: gmon.c
src/lib/libc/inet: inet_cidr_ntop.c inet_cidr_pton.c inet_net_pton.c
inet_neta.c inet_ntoa.c inet_pton.c
src/lib/libc/isc: ev_timers.c
src/lib/libc/md: mdXhl.c
src/lib/libc/misc: stack_protector.c
src/lib/libc/nameser: ns_name.c ns_netint.c ns_parse.c ns_print.c
ns_ttl.c
src/lib/libc/net: base64.c ethers.c getaddrinfo.c gethnamaddr.c
getifaddrs.c getnameinfo.c getnetent.c getnetnamadr.c
getservbyname_r.c getservbyport_r.c if_nameindex.c ip6opt.c
iso_addr.c linkaddr.c nsdispatch.c rcmd.c rthdr.c
src/lib/libc/quad: fixunsdfdi.c fixunssfdi.c floatdidf.c floatdisf.c
floatundidf.c floatundisf.c
src/lib/libc/regex: engine.c regcomp.c regexec.c
src/lib/libc/resolv: herror.c res_comp.c res_debug.c res_debug.h
res_init.c res_mkquery.c res_query.c res_send.c
src/lib/libc/rpc: authunix_prot.c bindresvport.c clnt_bcast.c clnt_vc.c
pmap_rmt.c rpc_generic.c rpc_prot.c rpcb_clnt.c rpcb_st_xdr.c
svc_auth_unix.c svc_dg.c svc_vc.c xdr.c xdr_rec.c
src/lib/libc/stdio: fflush.c fgetwc.c fputs.c fread.c fseeko.c
fvwrite.c fvwrite.h makebuf.c setvbuf.c snprintf.c sscanf.c stdio.c
vfscanf.c vfwprintf.c vfwscanf.c vsnprintf.c vsnprintf_ss.c
vsscanf.c vswscanf.c wbuf.c
src/lib/libc/stdlib: l64a.c merge.c strfmon.c
src/lib/libc/sys: sched.c
src/lib/libc/time: localtime.c strptime.c
src/lib/libc/yp: xdryp.c
Log Message:
PR/45989: Martin Husemann: lint invocation does include -w only on i386
- turn lint -w for all the platforms after fixing the lint warnings.
- add _DIAGASSERTS() for casts that would assign values to types that
would not fit.
- change types, add casts
- change into ansii prototypes
- turn on _DIAGNOSTIC for libc (during current, to be eliminated for release
builds)
approved by core@
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/Makefile.inc
cvs rdiff -u -r1.1 -r1.2 src/lib/libc/cdb/cdbw.c
cvs rdiff -u -r1.4 -r1.5 src/lib/libc/citrus/citrus_memstream.c
cvs rdiff -u -r1.1 -r1.2 src/lib/libc/compat/db/hash/compat_ndbmdatum.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/compat/gen/compat___fts13.c
cvs rdiff -u -r1.3 -r1.4 src/lib/libc/compat/gen/compat___fts30.c
cvs rdiff -u -r1.2 -r1.3 src/lib/libc/compat/gen/compat___fts31.c
cvs rdiff -u -r1.4 -r1.5 src/lib/libc/compat/sys/compat_getdents.c
cvs rdiff -u -r1.3 -r1.4 src/lib/libc/compat/sys/compat_sigaltstack.c
cvs rdiff -u -r1.25 -r1.26 src/lib/libc/db/btree/bt_open.c
cvs rdiff -u -r1.17 -r1.18 src/lib/libc/db/btree/bt_overflow.c
cvs rdiff -u -r1.31 -r1.32 src/lib/libc/db/hash/hash.c
cvs rdiff -u -r1.23 -r1.24 src/lib/libc/db/hash/hash_bigkey.c
cvs rdiff -u -r1.24 -r1.25 src/lib/libc/db/hash/hash_page.c
cvs rdiff -u -r1.4 -r1.5 src/lib/libc/db/hash/ndbmdatum.c
cvs rdiff -u -r1.11 -r1.12 src/lib/libc/dlfcn/dlfcn_elf.c
cvs rdiff -u -r1.5 -r1.6 src/lib/libc/gdtoa/gdtoa.c
cvs rdiff -u -r1.12 -r1.13 src/lib/libc/gdtoa/gdtoaimp.h
cvs rdiff -u -r1.3 -r1.4 src/lib/libc/gdtoa/gmisc.c
cvs rdiff -u -r1.4 -r1.5 src/lib/libc/gdtoa/smisc.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/gdtoa/strtod.c \
src/lib/libc/gdtoa/strtodg.c
cvs rdiff -u -r1.3 -r1.4 src/lib/libc/gen/dehumanize_number.c \
src/lib/libc/gen/extattr.c
cvs rdiff -u -r1.34 -r1.35 src/lib/libc/gen/disklabel.c
cvs rdiff -u -r1.30 -r1.31 src/lib/libc/gen/fstab.c src/lib/libc/gen/sysctl.c
cvs rdiff -u -r1.42 -r1.43 src/lib/libc/gen/fts.c
cvs rdiff -u -r1.50 -r1.51 src/lib/libc/gen/getcap.c \
src/lib/libc/gen/getcwd.c
cvs rdiff -u -r1.5 -r1.6 src/lib/libc/gen/getdevmajor.c
cvs rdiff -u -r1.64 -r1.65 src/lib/libc/gen/getgrent.c
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/gen/getloadavg.c
cvs rdiff -u -r1.28 -r1.29 src/lib/libc/gen/getusershell.c \
src/lib/libc/gen/utmpx.c
cvs rdiff -u -r1.14 -r1.15 src/lib/libc/gen/humanize_number.c
cvs rdiff -u -r1.2 -r1.3 src/lib/libc/gen/initdir.c
cvs rdiff -u -r1.22 -r1.23 src/lib/libc/gen/psignal.c \
src/lib/libc/gen/pw_scan.c
cvs rdiff -u -r1.26 -r1.27 src/lib/libc/gen/scandir.c
cvs rdiff -u -r1.9 -r1.10 src/lib/libc/gen/sysctlgetmibinfo.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/gen/sysctlnametomib.c
cvs rdiff -u -r1.49 -r1.50 src/lib/libc/gen/syslog.c
cvs rdiff -u -r1.11 -r1.12 src/lib/libc/gen/time.c
cvs rdiff -u -r1.38 -r1.39 src/lib/libc/gen/unvis.c
cvs rdiff -u -r1.33 -r1.34 src/lib/libc/gmon/gmon.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/inet/inet_cidr_ntop.c \
src/lib/libc/inet/inet_pton.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/inet/inet_cidr_pton.c
cvs rdiff -u -r1.2 -r1.3 src/lib/libc/inet/inet_net_pton.c
cvs rdiff -u -r1.1 -r1.2 src/lib/libc/inet/inet_neta.c \
src/lib/libc/inet/inet_ntoa.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/isc/ev_timers.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/md/mdXhl.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/misc/stack_protector.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/nameser/ns_name.c \
src/lib/libc/nameser/ns_parse.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/nameser/ns_netint.c
cvs rdiff -u -r1.10 -r1.11 src/lib/libc/nameser/ns_print.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/nameser/ns_ttl.c
cvs rdiff -u -r1.12 -r1.13 src/lib/libc/net/base64.c \
src/lib/libc/net/ip6opt.c src/lib/libc/net/iso_addr.c
cvs rdiff -u -r1.21 -r1.22 src/lib/libc/net/ethers.c
cvs rdiff -u -r1.96 -r1.97 src/lib/libc/net/getaddrinfo.c
cvs rdiff -u -r1.77 -r1.78 src/lib/libc/net/gethnamaddr.c
cvs rdiff -u -r1.14 -r1.15 src/lib/libc/net/getifaddrs.c \
src/lib/libc/net/linkaddr.c
cvs rdiff -u -r1.50 -r1.51 src/lib/libc/net/getnameinfo.c
cvs rdiff -u -r1.19 -r1.20 src/lib/libc/net/getnetent.c
cvs rdiff -u -r1.41 -r1.42 src/lib/libc/net/getnetnamadr.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/net/getservbyname_r.c \
src/lib/libc/net/getservbyport_r.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/net/if_nameindex.c
cvs rdiff -u -r1.36 -r1.37 src/lib/libc/net/nsdispatch.c
cvs rdiff -u -r1.66 -r1.67 src/lib/libc/net/rcmd.c
cvs rdiff -u -r1.17 -r1.18 src/lib/libc/net/rthdr.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/quad/fixunsdfdi.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/quad/fixunssfdi.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/quad/floatdidf.c \
src/lib/libc/quad/floatdisf.c
cvs rdiff -u -r1.1 -r1.2 src/lib/libc/quad/floatundidf.c \
src/lib/libc/quad/floatundisf.c
cvs rdiff -u -r1.23 -r1.24 src/lib/libc/regex/engine.c
cvs rdiff -u -r1.32 -r1.33 src/lib/libc/regex/regcomp.c
cvs rdiff -u -r1.21 -r1.22 src/lib/libc/regex/regexec.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/resolv/herror.c
cvs rdiff -u -r1.11 -r1.12 src/lib/libc/resolv/res_comp.c \
src/lib/libc/resolv/res_debug.c
cvs rdiff -u -r1.1.1.4 -r1.2 src/lib/libc/resolv/res_debug.h
cvs rdiff -u -r1.23 -r1.24 src/lib/libc/resolv/res_init.c
cvs rdiff -u -r1.12 -r1.13 src/lib/libc/resolv/res_mkquery.c
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/resolv/res_query.c
cvs rdiff -u -r1.22 -r1.23 src/lib/libc/resolv/res_send.c
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/rpc/authunix_prot.c
cvs rdiff -u -r1.21 -r1.22 src/lib/libc/rpc/bindresvport.c
cvs rdiff -u -r1.22 -r1.23 src/lib/libc/rpc/clnt_bcast.c
cvs rdiff -u -r1.17 -r1.18 src/lib/libc/rpc/clnt_vc.c
cvs rdiff -u -r1.30 -r1.31 src/lib/libc/rpc/pmap_rmt.c
cvs rdiff -u -r1.24 -r1.25 src/lib/libc/rpc/rpc_generic.c \
src/lib/libc/rpc/svc_vc.c
cvs rdiff -u -r1.18 -r1.19 src/lib/libc/rpc/rpc_prot.c \
src/lib/libc/rpc/svc_auth_unix.c
cvs rdiff -u -r1.25 -r1.26 src/lib/libc/rpc/rpcb_clnt.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/rpc/rpcb_st_xdr.c
cvs rdiff -u -r1.12 -r1.13 src/lib/libc/rpc/svc_dg.c
cvs rdiff -u -r1.28 -r1.29 src/lib/libc/rpc/xdr.c
cvs rdiff -u -r1.31 -r1.32 src/lib/libc/rpc/xdr_rec.c
cvs rdiff -u -r1.15 -r1.16 src/lib/libc/stdio/fflush.c \
src/lib/libc/stdio/makebuf.c
cvs rdiff -u -r1.11 -r1.12 src/lib/libc/stdio/fgetwc.c
cvs rdiff -u -r1.14 -r1.15 src/lib/libc/stdio/fputs.c
cvs rdiff -u -r1.20 -r1.21 src/lib/libc/stdio/fread.c
cvs rdiff -u -r1.9 -r1.10 src/lib/libc/stdio/fseeko.c
cvs rdiff -u -r1.22 -r1.23 src/lib/libc/stdio/fvwrite.c \
src/lib/libc/stdio/snprintf.c
cvs rdiff -u -r1.7 -r1.8 src/lib/libc/stdio/fvwrite.h
cvs rdiff -u -r1.17 -r1.18 src/lib/libc/stdio/setvbuf.c \
src/lib/libc/stdio/sscanf.c src/lib/libc/stdio/stdio.c
cvs rdiff -u -r1.41 -r1.42 src/lib/libc/stdio/vfscanf.c
cvs rdiff -u -r1.26 -r1.27 src/lib/libc/stdio/vfwprintf.c
cvs rdiff -u -r1.6 -r1.7 src/lib/libc/stdio/vfwscanf.c \
src/lib/libc/stdio/vswscanf.c
cvs rdiff -u -r1.23 -r1.24 src/lib/libc/stdio/vsnprintf.c
cvs rdiff -u -r1.10 -r1.11 src/lib/libc/stdio/vsnprintf_ss.c
cvs rdiff -u -r1.16 -r1.17 src/lib/libc/stdio/vsscanf.c
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/stdio/wbuf.c
cvs rdiff -u -r1.13 -r1.14 src/lib/libc/stdlib/l64a.c \
src/lib/libc/stdlib/merge.c
cvs rdiff -u -r1.8 -r1.9 src/lib/libc/stdlib/strfmon.c
cvs rdiff -u -r1.2 -r1.3 src/lib/libc/sys/sched.c
cvs rdiff -u -r1.65 -r1.66 src/lib/libc/time/localtime.c
cvs rdiff -u -r1.35 -r1.36 src/lib/libc/time/strptime.c
cvs rdiff -u -r1.30 -r1.31 src/lib/libc/yp/xdryp.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sat, 17 Mar 2012 10:53:22 +0000
State-Changed-Why:
Fixed.
State-Changed-From-To: closed->open
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sat, 17 Mar 2012 10:56:26 +0000
State-Changed-Why:
grr, spoke too soon. you've been joerg'd...
From: christos@zoulas.com (Christos Zoulas)
To: gnats-bugs@NetBSD.org, lib-bug-people@netbsd.org,
netbsd-bugs@netbsd.org, gnats-admin@netbsd.org, dholland@NetBSD.org,
martin@NetBSD.org
Cc:
Subject: Re: lib/45989 (libc lint invocation does include -w only on i386)
Date: Sat, 17 Mar 2012 12:58:16 -0400
On Mar 17, 10:53am, dholland@NetBSD.org (dholland@NetBSD.org) wrote:
-- Subject: Re: lib/45989 (libc lint invocation does include -w only on i386)
| Synopsis: libc lint invocation does include -w only on i386
|
| State-Changed-From-To: open->closed
| State-Changed-By: dholland@NetBSD.org
| State-Changed-When: Sat, 17 Mar 2012 10:53:22 +0000
| State-Changed-Why:
| Fixed.
Nope, joerg disabled it.
christos
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2014
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.