new copyright notice
[unix-history] / usr / src / lib / libc / gen / scandir.3
index 52040cc..8ad2c5c 100644 (file)
@@ -1,19 +1,9 @@
 .\" Copyright (c) 1983 Regents of the University of California.
 .\" All rights reserved.
 .\"
 .\" Copyright (c) 1983 Regents of the University of California.
 .\" All rights reserved.
 .\"
-.\" Redistribution and use in source and binary forms are permitted
-.\" provided that the above copyright notice and this paragraph are
-.\" duplicated in all such forms and that any documentation,
-.\" advertising materials, and other materials related to such
-.\" distribution and use acknowledge that the software was developed
-.\" by the University of California, Berkeley.  The name of the
-.\" University may not be used to endorse or promote products derived
-.\" from this software without specific prior written permission.
-.\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
-.\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
-.\" WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+.\" %sccs.include.redist.man%
 .\"
 .\"
-.\"    @(#)scandir.3   6.3 (Berkeley) %G%
+.\"    @(#)scandir.3   6.5 (Berkeley) %G%
 .\"
 .TH SCANDIR 3  ""
 .UC 5
 .\"
 .TH SCANDIR 3  ""
 .UC 5
@@ -26,7 +16,7 @@ scandir, alphasort \- scan a directory
 .PP
 .B scandir(dirname, namelist, select, compar)
 .B char *dirname;
 .PP
 .B scandir(dirname, namelist, select, compar)
 .B char *dirname;
-.B struct direct *(*namelist[]);
+.B struct direct ***namelist;
 .B int (*select)();
 .B int (*compar)();
 .PP
 .B int (*select)();
 .B int (*compar)();
 .PP
@@ -40,8 +30,9 @@ reads the directory
 and builds an array of pointers to directory
 entries using
 .IR malloc (3).
 and builds an array of pointers to directory
 entries using
 .IR malloc (3).
-It returns the number of entries in the array and a pointer to the
-array through
+It returns the number of entries in the array.
+A pointer to the array of directory entries is stored in the location
+referenced by
 .IR namelist .
 .PP
 The
 .IR namelist .
 .PP
 The