summaryrefslogtreecommitdiff
path: root/Build/source/libs/libgnuw32/system_popen_check.c
diff options
context:
space:
mode:
Diffstat (limited to 'Build/source/libs/libgnuw32/system_popen_check.c')
-rw-r--r--Build/source/libs/libgnuw32/system_popen_check.c27
1 files changed, 0 insertions, 27 deletions
diff --git a/Build/source/libs/libgnuw32/system_popen_check.c b/Build/source/libs/libgnuw32/system_popen_check.c
deleted file mode 100644
index f8fbe62dc5f..00000000000
--- a/Build/source/libs/libgnuw32/system_popen_check.c
+++ /dev/null
@@ -1,27 +0,0 @@
-#include "win32lib.h"
-
-main(int argc, char *argv[])
-{
- int ret;
- FILE *f;
- int c;
-
- if (argc != 3) {
- exit(1);
- }
- if (strncmp(argv[1], "syst", 4) == 0) {
- printf("Running cmd `%s'\n", argv[2]);
- ret = system(argv[2]);
- printf("return code = %d\n");
- }
- else if (strncmp(argv[1], "popr", 4) == 0) {
- f = popen(argv[2], "r");
- while ((c = fgetc(f)) != EOF) fputc(c, stdout);
- pclose(f);
- }
- else if (strncmp(argv[1], "popw", 4) == 0) {
- f = popen(argv[2], "w");
- while ((c = fgetc(stdin)) != EOF) fputc(c, f);
- pclose(f);
- }
-}