diff options
Diffstat (limited to '')
-rw-r--r-- | tmp/api-posix.c | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/tmp/api-posix.c b/tmp/api-posix.c deleted file mode 100644 index 9f51967..0000000 --- a/tmp/api-posix.c +++ /dev/null @@ -1,15 +0,0 @@ -/* POSIX implementation of "api.h" interface to be used in non-web contexts */ - -#include <stdio.h> - -void platformDependentPersistInt(int n) { - FILE* fp = fopen("/tmp/persisted.txt", "w+"); - fprintf(fp, "%d", n); - fclose(fp); -} - -int platformDependentRetrieveInt() { - FILE* fp = fopen("/tmp/persisted.txt", "r"); - int persisted = fgetc(fp); - return persisted; -} |