- Remove some header duplication.
authorAlex Ionescu <aionescu@gmail.com>
Sun, 13 Nov 2005 05:17:17 +0000 (05:17 +0000)
committerAlex Ionescu <aionescu@gmail.com>
Sun, 13 Nov 2005 05:17:17 +0000 (05:17 +0000)
svn path=/trunk/; revision=19191

reactos/boot/freeldr/freeldr/fs/fsrec.c
reactos/boot/freeldr/freeldr/fs/ntfs.c
reactos/boot/freeldr/freeldr/include/freeldr.h
reactos/boot/freeldr/freeldr/include/fs.h
reactos/boot/freeldr/freeldr/include/rtl.h

index e96c305..ace0bc8 100644 (file)
@@ -122,7 +122,7 @@ BOOL FsRecIsNtfs(ULONG DriveNumber, ULONG VolumeStartSector)
                return FALSE;
        }
 
                return FALSE;
        }
 
-       if (!RtlCompareMemory(BootSector->SystemId, "NTFS", 4))
+       if (RtlEqualMemory(BootSector->SystemId, "NTFS", 4))
        {
                return TRUE;
        }
        {
                return TRUE;
        }
index 1f8e513..d941f01 100644 (file)
@@ -102,7 +102,7 @@ static BOOL NtfsFindAttribute(PNTFS_ATTR_CONTEXT Context, PNTFS_MFT_RECORD MftRe
             if (AttrRecord->NameLength == NameLength)
             {
                 AttrName = (PWCHAR)((PCHAR)AttrRecord + AttrRecord->NameOffset);
             if (AttrRecord->NameLength == NameLength)
             {
                 AttrName = (PWCHAR)((PCHAR)AttrRecord + AttrRecord->NameOffset);
-                if (!RtlCompareMemory(AttrName, Name, NameLength << 1))
+                if (RtlEqualMemory(AttrName, Name, NameLength << 1))
                 {
                     /* Found it, fill up the context and return. */
                     Context->Record = AttrRecord;
                 {
                     /* Found it, fill up the context and return. */
                     Context->Record = AttrRecord;
@@ -611,7 +611,7 @@ BOOL NtfsOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector)
         return FALSE;
     }
 
         return FALSE;
     }
 
-    if (RtlCompareMemory(NtfsBootSector->SystemId, "NTFS", 4))
+    if (!RtlEqualMemory(NtfsBootSector->SystemId, "NTFS", 4))
     {
         FileSystemError("Invalid NTFS signature.");
         return FALSE;
     {
         FileSystemError("Invalid NTFS signature.");
         return FALSE;
index 203ee7c..74fdfaf 100644 (file)
 #ifndef __FREELDR_H
 #define __FREELDR_H
 
 #ifndef __FREELDR_H
 #define __FREELDR_H
 
+#define UINT64_C(val) val##ULL
+
+#include <stdlib.h>
+#include <stdio.h>
 #include <ddk/ntddk.h>
 #include <ndk/ntndk.h>
 #include <arch.h>
 #include <ddk/ntddk.h>
 #include <ndk/ntndk.h>
 #include <arch.h>
index 4f368f2..09a6e2b 100644 (file)
@@ -21,7 +21,7 @@
 #define __FS_H
 
 
 #define __FS_H
 
 
-#define        EOF                             -1
+//#define      EOF                             -1
 
 #define        FS_FAT                  1
 #define        FS_NTFS                 2
 
 #define        FS_FAT                  1
 #define        FS_NTFS                 2
index 088e72d..1c0e13d 100644 (file)
 
 #include <freeldr.h>
 
 
 #include <freeldr.h>
 
-///////////////////////////////////////////////////////////////////////////////////////
-//
-// Memory Functions
-//
-///////////////////////////////////////////////////////////////////////////////////////
-int            memcmp(const void *buf1, const void *buf2, size_t count);
-void * memcpy(void *to, const void *from, size_t count);
-void * memmove(void *dest, const void *src, size_t count);
-void * memset(void *src, int val, size_t count);
-
-#define RtlCompareMemory(Source1, Source2, Length)     memcmp(Source1, Source2, Length)
-
-///////////////////////////////////////////////////////////////////////////////////////
-//
-// Standard Library Functions
-//
-///////////////////////////////////////////////////////////////////////////////////////
-int            atoi(const char *string);
-char * itoa(int value, char *string, int radix);
-int            toupper(int c);
-int            tolower(int c);
-
-int            isspace(int c);
-int            isdigit(int c);
-int            isxdigit(int c);
-
 char * convert_to_ascii(char *buf, int c, int num);
 char * convert_i64_to_ascii(char *buf, int c, unsigned long long num);
 
 char * convert_to_ascii(char *buf, int c, int num);
 char * convert_i64_to_ascii(char *buf, int c, unsigned long long num);
 
@@ -55,25 +29,6 @@ void beep(void);
 void   delay(unsigned msec);
 void   sound(int freq);
 
 void   delay(unsigned msec);
 void   sound(int freq);
 
-#ifndef max
-#define max(a, b)  (((a) > (b)) ? (a) : (b))
-#endif
-
-#ifndef min
-#define min(a, b)  (((a) < (b)) ? (a) : (b))
-#endif
-
-#define UINT64_C(val) val##ULL
-
-///////////////////////////////////////////////////////////////////////////////////////
-//
-// Screen Output Functions
-//
-///////////////////////////////////////////////////////////////////////////////////////
-void   print(char *str);
-int            printf(const char *fmt, ...);
-int            sprintf(char *buffer, const char *format, ...);
-
 ///////////////////////////////////////////////////////////////////////////////////////
 //
 // List Functions
 ///////////////////////////////////////////////////////////////////////////////////////
 //
 // List Functions