|
Last change
on this file since 2527 was 2036, checked in by bird, 20 years ago |
|
Initial revision
|
-
Property cvs2svn:cvs-rev
set to
1.1
-
Property svn:eol-style
set to
native
-
Property svn:executable
set to
*
-
Property svn:keywords
set to
Author Date Id Revision
|
|
File size:
448 bytes
|
| Line | |
|---|
| 1 | #include <stdio.h>
|
|---|
| 2 | #include <stdlib.h>
|
|---|
| 3 | #include <string.h>
|
|---|
| 4 |
|
|---|
| 5 | char *files[500];
|
|---|
| 6 |
|
|---|
| 7 | int
|
|---|
| 8 | main (int argc, char *argv[])
|
|---|
| 9 | {
|
|---|
| 10 | FILE *fp;
|
|---|
| 11 | int i;
|
|---|
| 12 |
|
|---|
| 13 | for (i = 0; i < 500; i++) {
|
|---|
| 14 | files[i] = tempnam (NULL, "file");
|
|---|
| 15 | if (files[i] == NULL) {
|
|---|
| 16 | printf ("tempnam failed\n");
|
|---|
| 17 | exit (1);
|
|---|
| 18 | }
|
|---|
| 19 | printf ("file: %s\n", files[i]);
|
|---|
| 20 | fp = fopen (files[i], "w");
|
|---|
| 21 | fclose (fp);
|
|---|
| 22 | }
|
|---|
| 23 |
|
|---|
| 24 | for (i = 0; i < 500; i++)
|
|---|
| 25 | remove (files[i]);
|
|---|
| 26 |
|
|---|
| 27 | return 0;
|
|---|
| 28 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.