Module Name:    src
Committed By:   stacktic
Date:           Mon Nov  2 17:17:34 UTC 2009

Modified Files:
        src/lib/libc/gen: fts.c

Log Message:
Make sure fts_statp is NULL when FTS_NOSTAT is set


To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/lib/libc/gen/fts.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libc/gen/fts.c
diff -u src/lib/libc/gen/fts.c:1.39 src/lib/libc/gen/fts.c:1.40
--- src/lib/libc/gen/fts.c:1.39	Sun Aug 16 19:33:39 2009
+++ src/lib/libc/gen/fts.c	Mon Nov  2 17:17:34 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: fts.c,v 1.39 2009/08/16 19:33:39 christos Exp $	*/
+/*	$NetBSD: fts.c,v 1.40 2009/11/02 17:17:34 stacktic Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993, 1994
@@ -38,7 +38,7 @@
 #if 0
 static char sccsid[] = "@(#)fts.c	8.6 (Berkeley) 8/14/94";
 #else
-__RCSID("$NetBSD: fts.c,v 1.39 2009/08/16 19:33:39 christos Exp $");
+__RCSID("$NetBSD: fts.c,v 1.40 2009/11/02 17:17:34 stacktic Exp $");
 #endif
 #endif /* LIBC_SCCS and not lint */
 
@@ -1054,6 +1054,9 @@
 		}
 #endif
 
+        if (ISSET(FTS_NOSTAT))
+                p->fts_statp = NULL;
+
 	/* Copy the name plus the trailing NULL. */
 	memmove(p->fts_name, name, namelen + 1);
 

Reply via email to