ReactOS 0.4.16-dev-338-g34e76ad
freeldr.c File Reference
#include <freeldr.h>
#include <debug.h>
Include dependency graph for freeldr.c:

Go to the source code of this file.

Functions

 DBG_DEFAULT_CHANNEL (WARNING)
 
VOID __cdecl BootMain (IN PCCH CmdLine)
 
int __cdecl wctomb (char *mbchar, wchar_t wchar)
 
int __cdecl mbtowc (wchar_t *wchar, const char *mbchar, size_t count)
 
int __cdecl iswctype (wint_t wc, wctype_t wctypeFlags)
 
double pow (double x, double y)
 
double log (double x)
 
double log10 (double x)
 

Variables

CCHAR FrLdrBootPath [MAX_PATH] = ""
 

Function Documentation

◆ BootMain()

VOID __cdecl BootMain ( IN PCCH  CmdLine)

Definition at line 33 of file freeldr.c.

34{
35 /* Load the default settings from the command-line */
37
38 /* Debugger pre-initialization */
40
42
43 TRACE("BootMain() called.\n");
44
45#ifndef UEFIBOOT
46 /* Check if the CPU is new enough */
47 FrLdrCheckCpuCompatibility(); // FIXME: Should be done inside MachInit!
48#endif
49
50 /* UI pre-initialization */
51 if (!UiInitialize(FALSE))
52 {
53 UiMessageBoxCritical("Unable to initialize UI.");
54 goto Quit;
55 }
56
57 /* Initialize memory manager */
59 {
60 UiMessageBoxCritical("Unable to initialize memory manager.");
61 goto Quit;
62 }
63
64 /* Initialize I/O subsystem */
65 FsInit();
66
67 /* Initialize the module list */
69 {
70 UiMessageBoxCritical("Unable to initialize module list.");
71 goto Quit;
72 }
73
74 RunLoader();
75
76Quit:
77 /* If we reach this point, something went wrong before, therefore reboot */
78 Reboot();
79}
void LoadSettings(void)
Definition: settings.c:53
@ Reboot
Definition: bl.h:891
#define DebugInit(DebugString)
Definition: debug.h:120
VOID FsInit(VOID)
Definition: fs.c:646
BOOLEAN MmInitializeMemoryManager(VOID)
Definition: meminit.c:315
BOOTMGRINFO BootMgrInfo
Definition: settings.c:18
VOID UiMessageBoxCritical(_In_ PCSTR MessageText)
Definition: ui.c:372
BOOLEAN UiInitialize(BOOLEAN ShowUi)
Definition: ui.c:92
#define FALSE
Definition: types.h:117
static const WCHAR CmdLine[]
Definition: install.c:48
VOID RunLoader(VOID)
Definition: bootmgr.c:356
VOID FrLdrCheckCpuCompatibility(VOID)
Definition: macharm.c:65
VOID MachInit(IN PCCH CommandLine)
Definition: macharm.c:182
BOOLEAN PeLdrInitializeModuleList(VOID)
Definition: peloader.c:525
#define TRACE(s)
Definition: solgame.cpp:4
PCSTR DebugString
Definition: settings.h:12

Referenced by ArmInit(), and RealEntryPoint().

◆ DBG_DEFAULT_CHANNEL()

DBG_DEFAULT_CHANNEL ( WARNING  )

◆ iswctype()

int __cdecl iswctype ( wint_t  wc,
wctype_t  wctypeFlags 
)

Definition at line 97 of file freeldr.c.

98{
99 return _isctype((char)wc, wctypeFlags);
100}
_Check_return_ _CRTIMP int __cdecl _isctype(_In_ int _C, _In_ int _Type)

Referenced by _wcstoi64_l(), _wcstoui64_l(), _wtoi64_l(), _wtol(), iswalnum(), iswalpha(), iswblank(), iswcntrl(), iswdigit(), iswgraph(), iswlower(), iswprint(), iswpunct(), iswspace(), iswupper(), iswxdigit(), rangematch(), towlower(), towupper(), wcstol(), and wcstoul().

◆ log()

double log ( double  x)

Definition at line 116 of file freeldr.c.

117{
118 __debugbreak();
119 return 0.0;
120}
void __cdecl __debugbreak(void)
Definition: intrin_ppc.h:698

◆ log10()

◆ mbtowc()

int __cdecl mbtowc ( wchar_t wchar,
const char mbchar,
size_t  count 
)

Definition at line 90 of file freeldr.c.

91{
92 *wchar = (wchar_t)*mbchar;
93 return 1;
94}
#define wchar_t
Definition: wchar.h:102

◆ pow()

◆ wctomb()

int __cdecl wctomb ( char mbchar,
wchar_t  wchar 
)

Definition at line 84 of file freeldr.c.

85{
86 *mbchar = (char)wchar;
87 return 1;
88}
unsigned char
Definition: typeof.h:29

Variable Documentation

◆ FrLdrBootPath