Add _fstat64i32.
Robert Wilhelm (none)
robert at gaston.
Wed May 26 03:34:51 CDT 2010
---
dlls/msvcr90/msvcr90.c | 32 ++++++++++++++++++++++++++++++++
dlls/msvcr90/msvcr90.spec | 2 +-
2 files changed, 33 insertions(+), 1 deletions(-)
diff --git a/dlls/msvcr90/msvcr90.c b/dlls/msvcr90/msvcr90.c
index eaf9d66..92c4ef0 100644
--- a/dlls/msvcr90/msvcr90.c
+++ b/dlls/msvcr90/msvcr90.c
@@ -26,6 +26,7 @@
#include "windef.h"
#include "winbase.h"
#include "wine/debug.h"
+#include "sys/stat.h"
WINE_DEFAULT_DEBUG_CHANNEL(msvcr90);
@@ -158,3 +159,34 @@ void* CDECL _recalloc(void* mem, size_t num, size_t size)
memset((BYTE*)mem+old_size, 0, size-old_size);
return ret;
}
+
+/*********************************************************************
+ * _fstat64i32 (MSVCRT.@)
+ */
+
+static void msvcrt_stat64_to_stat64i32(const struct _stat64 *buf64, struct _stat64i32 *buf)
+{
+ buf->st_dev = buf64->st_dev;
+ buf->st_ino = buf64->st_ino;
+ buf->st_mode = buf64->st_mode;
+ buf->st_nlink = buf64->st_nlink;
+ buf->st_uid = buf64->st_uid;
+ buf->st_gid = buf64->st_gid;
+ buf->st_rdev = buf64->st_rdev;
+ buf->st_size = buf64->st_size;
+ buf->st_atime = buf64->st_atime;
+ buf->st_mtime = buf64->st_mtime;
+ buf->st_ctime = buf64->st_ctime;
+}
+
+int CDECL _fstat64i32(int fd, struct _stat64i32* buf)
+{
+ int ret;
+ struct _stat64 buf64;
+
+ ret = _fstat64(fd, &buf64);
+ if (!ret)
+ msvcrt_stat64_to_stat64i32(&buf64, buf);
+ return ret;
+}
+
diff --git a/dlls/msvcr90/msvcr90.spec b/dlls/msvcr90/msvcr90.spec
index be4a675..f350d18 100644
--- a/dlls/msvcr90/msvcr90.spec
+++ b/dlls/msvcr90/msvcr90.spec
@@ -433,7 +433,7 @@
@ stub _fstat32
@ stub _fstat32i64
@ cdecl _fstat64(long ptr) msvcrt._fstat64
-@ stub _fstat64i32
+@ cdecl _fstat64i32(long ptr)
@ stub _ftell_nolock
@ stub _ftelli64
@ stub _ftelli64_nolock
--
1.6.6.1
--=-NUHaEZ8DHkf7WRenrmaU--
More information about the wine-patches
mailing list