Merge pull request #13979 from phcoder/dostime

djgpp: Add a workaround for libc bug
This commit is contained in:
LibretroAdmin 2022-05-29 05:32:50 +01:00 committed by GitHub
commit 4e5cc3fef1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -16,6 +16,7 @@
#include <stdint.h>
#include <stdio.h>
#include <time.h>
#include <process.h>
#include <string/stdstring.h>
#include <file/file_path.h>
@ -29,7 +30,9 @@ static enum frontend_fork dos_fork_mode = FRONTEND_FORK_NONE;
static void frontend_dos_init(void *data)
{
printf("Loading RetroArch...\n");
// Keep a call to time() as otherwise we trigger some obscure bug in
// djgpp libc code and time(NULL) return only -1
printf("Loading RetroArch. Time is @%ld...\n", (long) time(NULL));
}
static void frontend_dos_shutdown(bool unused)