Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Jun 2001 21:35:43 +0300
From:      Ruslan Ermilov <ru@FreeBSD.org>
To:        current@FreeBSD.org
Subject:   Re: ** HEADS UP **: -nostdinc -Wfoo ==> -DNO_WERROR is temporarily the default for `buildworld'
Message-ID:  <20010611213543.A50405@sunbay.com>
In-Reply-To: <20010611212628.A37954@sunbay.com>; from ru@FreeBSD.org on Mon, Jun 11, 2001 at 09:26:28PM %2B0300
References:  <20010611212628.A37954@sunbay.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--Qxx1br4bt0+wmkIi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Mon, Jun 11, 2001 at 09:26:28PM +0300, Ruslan Ermilov wrote:
[...]
> While this is definitely a problem in fts.h, which is fixed with the
> attached patch, it is unclear why this warning is hidden after the
> -nostdinc.
> 
For those interested, here's the missing patch.


-- 
Ruslan Ermilov		Oracle Developer/DBA,
ru@sunbay.com		Sunbay Software AG,
ru@FreeBSD.org		FreeBSD committer,
+380.652.512.251	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age

--Qxx1br4bt0+wmkIi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename=p

Index: include/fts.h
===================================================================
RCS file: /home/ncvs/src/include/fts.h,v
retrieving revision 1.3
diff -u -p -r1.3 fts.h
--- include/fts.h	1997/05/07 19:59:58	1.3
+++ include/fts.h	2001/06/11 18:20:14
@@ -45,7 +45,8 @@ typedef struct {
 	int fts_rfd;			/* fd for root */
 	int fts_pathlen;		/* sizeof(path) */
 	int fts_nitems;			/* elements in the sort array */
-	int (*fts_compar)();		/* compare function */
+	int (*fts_compar)		/* compare function */
+	    __P((const struct _ftsent **, const struct _ftsent **));
 
 #define	FTS_COMFOLLOW	0x001		/* follow command line symlinks */
 #define	FTS_LOGICAL	0x002		/* logical walk */
Index: lib/libc/gen/fts.c
===================================================================
RCS file: /home/ncvs/src/lib/libc/gen/fts.c,v
retrieving revision 1.18
diff -u -p -r1.18 fts.c
--- lib/libc/gen/fts.c	2001/06/01 21:53:50	1.18
+++ lib/libc/gen/fts.c	2001/06/11 18:20:17
@@ -936,7 +936,8 @@ fts_sort(sp, head, nitems)
 	}
 	for (ap = sp->fts_array, p = head; p; p = p->fts_link)
 		*ap++ = p;
-	qsort((void *)sp->fts_array, nitems, sizeof(FTSENT *), sp->fts_compar);
+	qsort((void *)sp->fts_array, nitems, sizeof(FTSENT *),
+	    (int (*) __P((const void *, const void *)))sp->fts_compar);
 	for (head = *(ap = sp->fts_array); --nitems; ++ap)
 		ap[0]->fts_link = ap[1];
 	ap[0]->fts_link = NULL;

--Qxx1br4bt0+wmkIi--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010611213543.A50405>