(svn r9055) -Codechange: Change windows unicode handling and allow a pure non-unicode build to function. Win9x binaries will be possible with mingw/nightly system.

This commit is contained in:
Darkvater
2007-03-07 18:58:28 +00:00
parent 663bf46352
commit 1a2576cd7e
6 changed files with 149 additions and 77 deletions

View File

@@ -59,7 +59,7 @@ int CDECL compare_FiosItems(const void *a, const void *b);
struct DIR;
struct dirent { // XXX - only d_name implemented
wchar_t *d_name; // name of found file
TCHAR *d_name; // name of found file
/* little hack which will point to parent DIR struct which will
* save us a call to GetFileAttributes if we want information
* about the file (for example in function fio_bla) */
@@ -72,14 +72,14 @@ struct DIR {
* note: having only one global instance is not possible because
* multiple independent opendir/readdir sequences must be supported. */
dirent ent;
WIN32_FIND_DATAW fd;
WIN32_FIND_DATA fd;
/* since opendir calls FindFirstFile, we need a means of telling the
* first call to readdir that we already have a file.
* that's the case iff this is true */
bool at_first_entry;
};
DIR *opendir(const wchar_t *path);
DIR *opendir(const TCHAR *path);
struct dirent *readdir(DIR *d);
int closedir(DIR *d);
#else