Patch : fix alignment issue in RtlSecondsSince1970ToTime for Sparc-Solaris

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 






ChangeLog

    - fixed an alignment/endian issue in RtlSecondsSince1970ToTime


Warren Baird : Warren_Baird@cimmetry.com


diff -ur clean/wine-20020509/dlls/ntdll/time.c wine-20020509/dlls/ntdll/time.c
--- clean/wine-20020509/dlls/ntdll/time.c     Sat Mar  9 18:39:09 2002
+++ wine-20020509/dlls/ntdll/time.c      Thu May 16 10:46:15 2002
@@ -231,7 +231,14 @@
 void WINAPI RtlSecondsSince1970ToTime( DWORD time, FILETIME *res )
 {
     LONGLONG secs = time + SECS_1601_TO_1970;
+
+#ifdef WORDS_BIGENDIAN
+    LONGLONG newTime = RtlExtendedIntegerMultiply( secs, 10000000 );
+    res->dwHighDateTime = newTime >> 32;
+    res->dwLowDateTime = newTime & 0xffffffff;
+#else
     ((LARGE_INTEGER *)res)->QuadPart = RtlExtendedIntegerMultiply( secs,
10000000 );
+#endif
 }

 /******************************************************************************




[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux