summaryrefslogtreecommitdiff
path: root/test/stdio/fclose-loop.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/stdio/fclose-loop.c')
-rw-r--r--test/stdio/fclose-loop.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/test/stdio/fclose-loop.c b/test/stdio/fclose-loop.c
deleted file mode 100644
index fc0cc424a..000000000
--- a/test/stdio/fclose-loop.c
+++ /dev/null
@@ -1,21 +0,0 @@
-/* From: Denis Vlasenko <vda.linux@googlemail.com>
- * With certain combination of .config options fclose() does not
- * remove FILE* pointer from _stdio_openlist. As a result, subsequent
- * fopen() may allocate new FILE structure exactly in place of one
- * freed by previous fclose(), which then makes _stdio_openlist
- * circularlt looped. The following program will enter infinite loop
- * trying to walk _stdio_openlist in exit():
- */
-
-#include <stdlib.h>
-#include <stdio.h>
-
-int main(int argc, char *argv[])
-{
- FILE* fp;
- fp = fopen("/dev/null", "r");
- fclose(fp);
- fp = fopen("/dev/zero", "r");
- fclose(fp);
- return 0;
-}