Load and write our settings in re3.ini & fixes

This commit is contained in:
eray orçunus 2020-10-02 17:36:56 +03:00
parent ee3f5744f5
commit 3bd3330227
12 changed files with 150 additions and 78 deletions

View file

@ -84,6 +84,16 @@ void FileTimeToSystemTime(time_t* writeTime, SYSTEMTIME* out) {
}
#endif
// Because wchar length differs between platforms.
wchar*
AllocUnicode(const char* src)
{
wchar *dst = (wchar*)malloc(strlen(src)*2 + 2);
wchar *i = dst;
while((*i++ = (unsigned char)*src++) != '\0');
return dst;
}
// Funcs/features from Windows that we need on other platforms
#ifndef _WIN32
char *strupr(char *s) {