summaryrefslogtreecommitdiff
path: root/rushs/tinyprintf/io_merge_files/merge_files.c
diff options
context:
space:
mode:
authorMartial Simon <msimon_fr@hotmail.com>2025-10-11 22:19:00 +0200
committerMartial Simon <msimon_fr@hotmail.com>2025-10-11 22:19:00 +0200
commit73c2b00a10c5786ddeeacc915e233fd4df1c9321 (patch)
treee299ea4e8ac161b2b21170172ff8f182c1c3fe1a /rushs/tinyprintf/io_merge_files/merge_files.c
parentc9b6b9a5ca082fe7c1b6f58d7713f785a9eb6a5c (diff)
fix: evalexpr & tinyprintf contenaient toute la piscine
Diffstat (limited to 'rushs/tinyprintf/io_merge_files/merge_files.c')
-rw-r--r--rushs/tinyprintf/io_merge_files/merge_files.c31
1 files changed, 0 insertions, 31 deletions
diff --git a/rushs/tinyprintf/io_merge_files/merge_files.c b/rushs/tinyprintf/io_merge_files/merge_files.c
deleted file mode 100644
index 26ac9cf..0000000
--- a/rushs/tinyprintf/io_merge_files/merge_files.c
+++ /dev/null
@@ -1,31 +0,0 @@
-#define _POSIX_C_SOURCE 200809L
-
-#include <stdio.h>
-
-int merge_files(const char *file_1, const char *file_2)
-{
- FILE *a = fopen(file_1, "a");
- if (a == NULL)
- {
- return -1;
- }
- FILE *r = fopen(file_2, "r");
- if (r == NULL)
- {
- return -1;
- }
-
- int c;
- while ((c = fgetc(r)) != EOF)
- {
- if (fputc(c, a) == EOF)
- {
- return -1;
- }
- }
-
- fclose(a);
- fclose(r);
-
- return 0;
-}