Commit in reactos/lib/kernel32/file on MAIN
file.c+10-41.56 -> 1.57
find.c+47-381.45 -> 1.46
+57-42
2 modified files
don't copy LARGE_INTEGER structs to FILETIME structs with memcpy, it works but it's confusing as they're different structures that happen to be identical.

reactos/lib/kernel32/file
file.c 1.56 -> 1.57
diff -u -r1.56 -r1.57
--- file.c	24 Jul 2004 01:27:54 -0000	1.56
+++ file.c	6 Sep 2004 15:56:25 -0000	1.57
@@ -1,4 +1,4 @@
-/* $Id: file.c,v 1.56 2004/07/24 01:27:54 navaraf Exp $
+/* $Id: file.c,v 1.57 2004/09/06 15:56:25 weiden Exp $
  *
  * COPYRIGHT:       See COPYING in the top level directory
  * PROJECT:         ReactOS system libraries
@@ -623,9 +623,15 @@
      }
 
    lpFileInformation->dwFileAttributes = (DWORD)FileBasic.FileAttributes;
-   memcpy(&lpFileInformation->ftCreationTime,&FileBasic.CreationTime,sizeof(LARGE_INTEGER));
-   memcpy(&lpFileInformation->ftLastAccessTime,&FileBasic.LastAccessTime,sizeof(LARGE_INTEGER));
-   memcpy(&lpFileInformation->ftLastWriteTime, &FileBasic.LastWriteTime,sizeof(LARGE_INTEGER));
+   
+   lpFileInformation->ftCreationTime.dwHighDateTime = FileBasic.CreationTime.u.HighPart;
+   lpFileInformation->ftCreationTime.dwLowDateTime = FileBasic.CreationTime.u.LowPart;
+
+   lpFileInformation->ftLastAccessTime.dwHighDateTime = FileBasic.LastAccessTime.u.HighPart;
+   lpFileInformation->ftLastAccessTime.dwLowDateTime = FileBasic.LastAccessTime.u.LowPart;
+   
+   lpFileInformation->ftLastWriteTime.dwHighDateTime = FileBasic.LastWriteTime.u.HighPart;
+   lpFileInformation->ftLastWriteTime.dwLowDateTime = FileBasic.LastWriteTime.u.LowPart;
 
    errCode = NtQueryInformationFile(hFile,
 				    &IoStatusBlock,

reactos/lib/kernel32/file
find.c 1.45 -> 1.46
diff -u -r1.45 -r1.46
--- find.c	28 Aug 2004 22:07:51 -0000	1.45
+++ find.c	6 Sep 2004 15:56:25 -0000	1.46
@@ -1,4 +1,4 @@
-/* $Id: find.c,v 1.45 2004/08/28 22:07:51 navaraf Exp $
+/* $Id: find.c,v 1.46 2004/09/06 15:56:25 weiden Exp $
  *
  * COPYRIGHT:       See COPYING in the top level directory
  * PROJECT:         ReactOS system libraries
@@ -350,15 +350,16 @@
 
 	/* copy data into WIN32_FIND_DATA structure */
 	lpFindFileData->dwFileAttributes = IData->pFileInfo->FileAttributes;
-	memcpy (&lpFindFileData->ftCreationTime,
-	        &IData->pFileInfo->CreationTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastAccessTime,
-	        &IData->pFileInfo->LastAccessTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastWriteTime,
-	        &IData->pFileInfo->LastWriteTime,
-	        sizeof(FILETIME));
+	
+	lpFindFileData->ftCreationTime.dwHighDateTime = IData->pFileInfo->CreationTime.u.HighPart;
+	lpFindFileData->ftCreationTime.dwLowDateTime = IData->pFileInfo->CreationTime.u.LowPart;
+	
+	lpFindFileData->ftLastAccessTime.dwHighDateTime = IData->pFileInfo->LastAccessTime.u.HighPart;
+	lpFindFileData->ftLastAccessTime.dwLowDateTime = IData->pFileInfo->LastAccessTime.u.LowPart;
+	
+	lpFindFileData->ftLastWriteTime.dwHighDateTime = IData->pFileInfo->LastWriteTime.u.HighPart;
+	lpFindFileData->ftLastWriteTime.dwLowDateTime = IData->pFileInfo->LastWriteTime.u.LowPart;
+
 	lpFindFileData->nFileSizeHigh = IData->pFileInfo->EndOfFile.u.HighPart;
 	lpFindFileData->nFileSizeLow = IData->pFileInfo->EndOfFile.u.LowPart;
 
@@ -437,15 +438,16 @@
 
 	/* copy data into WIN32_FIND_DATA structure */
 	lpFindFileData->dwFileAttributes = IData->pFileInfo->FileAttributes;
-	memcpy (&lpFindFileData->ftCreationTime,
-	        &IData->pFileInfo->CreationTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastAccessTime,
-	        &IData->pFileInfo->LastAccessTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastWriteTime,
-	        &IData->pFileInfo->LastWriteTime,
-	        sizeof(FILETIME));
+	
+	lpFindFileData->ftCreationTime.dwHighDateTime = IData->pFileInfo->CreationTime.u.HighPart;
+	lpFindFileData->ftCreationTime.dwLowDateTime = IData->pFileInfo->CreationTime.u.LowPart;
+
+	lpFindFileData->ftLastAccessTime.dwHighDateTime = IData->pFileInfo->LastAccessTime.u.HighPart;
+	lpFindFileData->ftLastAccessTime.dwLowDateTime = IData->pFileInfo->LastAccessTime.u.LowPart;
+
+	lpFindFileData->ftLastWriteTime.dwHighDateTime = IData->pFileInfo->LastWriteTime.u.HighPart;
+	lpFindFileData->ftLastWriteTime.dwLowDateTime = IData->pFileInfo->LastWriteTime.u.LowPart;
+
 	lpFindFileData->nFileSizeHigh = IData->pFileInfo->EndOfFile.u.HighPart;
 	lpFindFileData->nFileSizeLow = IData->pFileInfo->EndOfFile.u.LowPart;
 
@@ -541,17 +543,19 @@
 
 	/* copy data into WIN32_FIND_DATA structure */
 	lpFindFileData->dwFileAttributes = IData->pFileInfo->FileAttributes;
-	memcpy (&lpFindFileData->ftCreationTime,
-	        &IData->pFileInfo->CreationTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastAccessTime,
-	        &IData->pFileInfo->LastAccessTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastWriteTime,
-	        &IData->pFileInfo->LastWriteTime,
-	        sizeof(FILETIME));
+	
+	lpFindFileData->ftCreationTime.dwHighDateTime = IData->pFileInfo->CreationTime.u.HighPart;
+	lpFindFileData->ftCreationTime.dwLowDateTime = IData->pFileInfo->CreationTime.u.LowPart;
+
+	lpFindFileData->ftLastAccessTime.dwHighDateTime = IData->pFileInfo->LastAccessTime.u.HighPart;
+	lpFindFileData->ftLastAccessTime.dwLowDateTime = IData->pFileInfo->LastAccessTime.u.LowPart;
+
+	lpFindFileData->ftLastWriteTime.dwHighDateTime = IData->pFileInfo->LastWriteTime.u.HighPart;
+	lpFindFileData->ftLastWriteTime.dwLowDateTime = IData->pFileInfo->LastWriteTime.u.LowPart;
+	
 	lpFindFileData->nFileSizeHigh = IData->pFileInfo->EndOfFile.u.HighPart;
 	lpFindFileData->nFileSizeLow = IData->pFileInfo->EndOfFile.u.LowPart;
+	
 	memcpy (lpFindFileData->cFileName,
 	        IData->pFileInfo->FileName,
 	        IData->pFileInfo->FileNameLength);
@@ -592,18 +596,23 @@
 
 	/* copy data into WIN32_FIND_DATA structure */
 	lpFindFileData->dwFileAttributes = IData->pFileInfo->FileAttributes;
-	memcpy (&lpFindFileData->ftCreationTime,
-	        &IData->pFileInfo->CreationTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastAccessTime,
-	        &IData->pFileInfo->LastAccessTime,
-	        sizeof(FILETIME));
-	memcpy (&lpFindFileData->ftLastWriteTime,
-	        &IData->pFileInfo->LastWriteTime,
-	        sizeof(FILETIME));
+
+	lpFindFileData->ftCreationTime.dwHighDateTime = IData->pFileInfo->CreationTime.u.HighPart;
+	lpFindFileData->ftCreationTime.dwLowDateTime = IData->pFileInfo->CreationTime.u.LowPart;
+
+	lpFindFileData->ftLastAccessTime.dwHighDateTime = IData->pFileInfo->LastAccessTime.u.HighPart;
+	lpFindFileData->ftLastAccessTime.dwLowDateTime = IData->pFileInfo->LastAccessTime.u.LowPart;
+
+	lpFindFileData->ftLastWriteTime.dwHighDateTime = IData->pFileInfo->LastWriteTime.u.HighPart;
+	lpFindFileData->ftLastWriteTime.dwLowDateTime = IData->pFileInfo->LastWriteTime.u.LowPart;
+
 	lpFindFileData->nFileSizeHigh = IData->pFileInfo->EndOfFile.u.HighPart;
 	lpFindFileData->nFileSizeLow = IData->pFileInfo->EndOfFile.u.LowPart;
-	memcpy (lpFindFileData->cFileName,
+
+	lpFindFileData->nFileSizeHigh = IData->pFileInfo->EndOfFile.u.HighPart;
+	lpFindFileData->nFileSizeLow = IData->pFileInfo->EndOfFile.u.LowPart;
+
+        memcpy (lpFindFileData->cFileName,
 	        IData->pFileInfo->FileName,
 	        IData->pFileInfo->FileNameLength);
 	lpFindFileData->cFileName[IData->pFileInfo->FileNameLength / sizeof(WCHAR)] = 0;
CVSspam 0.2.8