mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 10:22:59 +00:00
New macros InitializeUnicodeString(), RtlInitUnicodeStringFromLiteral() and UNICODE_STRING_INITIALIZATOR(), for fast, compile-time initialization of UNICODE_STRING variables
svn path=/trunk/; revision=3371
This commit is contained in:
parent
51f0384fc0
commit
d8bd5ccb4a
70 changed files with 283 additions and 279 deletions
|
@ -20,7 +20,7 @@ int main(int argc, char* argv[])
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
HANDLE FileHandle;
|
HANDLE FileHandle;
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
UNICODE_STRING FileName;
|
UNICODE_STRING FileName = UNICODE_STRING_INITIALIZER(L"\\C:\\a.txt");
|
||||||
IO_STATUS_BLOCK IoStatus;
|
IO_STATUS_BLOCK IoStatus;
|
||||||
CHAR Buffer[256];
|
CHAR Buffer[256];
|
||||||
HANDLE EventHandle;
|
HANDLE EventHandle;
|
||||||
|
@ -42,8 +42,6 @@ int main(int argc, char* argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("Opening file\n");
|
printf("Opening file\n");
|
||||||
RtlInitUnicodeString(&FileName,
|
|
||||||
L"\\C:\\a.txt");
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&FileName,
|
&FileName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: lpcclt.c,v 1.8 2002/02/24 17:44:22 ea Exp $
|
/* $Id: lpcclt.c,v 1.9 2002/08/20 20:37:03 hyperion Exp $
|
||||||
*
|
*
|
||||||
* DESCRIPTION: Simple LPC Client
|
* DESCRIPTION: Simple LPC Client
|
||||||
* PROGRAMMER: David Welch
|
* PROGRAMMER: David Welch
|
||||||
|
@ -31,7 +31,7 @@ void debug_printf(char* fmt, ...)
|
||||||
|
|
||||||
int main(int argc, char* argv[])
|
int main(int argc, char* argv[])
|
||||||
{
|
{
|
||||||
UNICODE_STRING PortName;
|
UNICODE_STRING PortName = UNICODE_STRING_INITIALIZER(TEST_PORT_NAME_U);
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
HANDLE PortHandle;
|
HANDLE PortHandle;
|
||||||
LPC_MAX_MESSAGE Request;
|
LPC_MAX_MESSAGE Request;
|
||||||
|
@ -41,8 +41,6 @@ int main(int argc, char* argv[])
|
||||||
|
|
||||||
printf("%s: Lpc test client\n", MyName);
|
printf("%s: Lpc test client\n", MyName);
|
||||||
|
|
||||||
RtlInitUnicodeString(&PortName, TEST_PORT_NAME_U);
|
|
||||||
|
|
||||||
printf("%s: Connecting to port \"%s\"...\n", MyName, TEST_PORT_NAME);
|
printf("%s: Connecting to port \"%s\"...\n", MyName, TEST_PORT_NAME);
|
||||||
ConnectInfoLength = 0;
|
ConnectInfoLength = 0;
|
||||||
ZeroMemory (& Sqos, sizeof Sqos);
|
ZeroMemory (& Sqos, sizeof Sqos);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: lpcsrv.c,v 1.8 2002/02/24 17:44:22 ea Exp $
|
/* $Id: lpcsrv.c,v 1.9 2002/08/20 20:37:04 hyperion Exp $
|
||||||
*
|
*
|
||||||
* DESCRIPTION: Simple LPC Server
|
* DESCRIPTION: Simple LPC Server
|
||||||
* PROGRAMMER: David Welch
|
* PROGRAMMER: David Welch
|
||||||
|
@ -32,7 +32,7 @@ void debug_printf(char* fmt, ...)
|
||||||
|
|
||||||
int main(int argc, char* argv[])
|
int main(int argc, char* argv[])
|
||||||
{
|
{
|
||||||
UNICODE_STRING PortName;
|
UNICODE_STRING PortName = UNICODE_STRING_INITIALIZER(TEST_PORT_NAME_U);
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
HANDLE NamedPortHandle;
|
HANDLE NamedPortHandle;
|
||||||
|
@ -41,7 +41,6 @@ int main(int argc, char* argv[])
|
||||||
|
|
||||||
printf("%s: Lpc test server\n", MyName);
|
printf("%s: Lpc test server\n", MyName);
|
||||||
|
|
||||||
RtlInitUnicodeString(&PortName, TEST_PORT_NAME_U);
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&PortName,
|
&PortName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -54,13 +54,12 @@ void test1(void)
|
||||||
HKEY hKey = NULL,hKey1;
|
HKEY hKey = NULL,hKey1;
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
UNICODE_STRING KeyName;
|
UNICODE_STRING KeyName = UNICODE_STRING_INITIALIZER(L"\\Registry");
|
||||||
ULONG Index,Length,i;
|
ULONG Index,Length,i;
|
||||||
KEY_BASIC_INFORMATION KeyInformation[5];
|
KEY_BASIC_INFORMATION KeyInformation[5];
|
||||||
KEY_VALUE_FULL_INFORMATION KeyValueInformation[5];
|
KEY_VALUE_FULL_INFORMATION KeyValueInformation[5];
|
||||||
|
|
||||||
dprintf("NtOpenKey \\Registry : ");
|
dprintf("NtOpenKey \\Registry : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry");
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -104,7 +103,7 @@ void test1(void)
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
|
|
||||||
dprintf("NtOpenKey \\Registry\\Machine : ");
|
dprintf("NtOpenKey \\Registry\\Machine : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -114,7 +113,7 @@ void test1(void)
|
||||||
dprintf("\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\tStatus =%x\n",Status);
|
||||||
|
|
||||||
dprintf("NtOpenKey System\\Setup : ");
|
dprintf("NtOpenKey System\\Setup : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"System\\Setup");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"System\\Setup");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, hKey1 , NULL);
|
, hKey1 , NULL);
|
||||||
Status = NtOpenKey ( &hKey, KEY_READ , &ObjectAttributes);
|
Status = NtOpenKey ( &hKey, KEY_READ , &ObjectAttributes);
|
||||||
|
@ -122,7 +121,7 @@ void test1(void)
|
||||||
if(Status==0)
|
if(Status==0)
|
||||||
{
|
{
|
||||||
dprintf("NtQueryValueKey : ");
|
dprintf("NtQueryValueKey : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"CmdLine");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"CmdLine");
|
||||||
Status=NtQueryValueKey(hKey,&KeyName,KeyValueFullInformation
|
Status=NtQueryValueKey(hKey,&KeyName,KeyValueFullInformation
|
||||||
,&KeyValueInformation[0], sizeof(KeyValueInformation)
|
,&KeyValueInformation[0], sizeof(KeyValueInformation)
|
||||||
,&Length);
|
,&Length);
|
||||||
|
@ -169,6 +168,7 @@ void test1(void)
|
||||||
NtClose( hKey1 );
|
NtClose( hKey1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void test2(void)
|
void test2(void)
|
||||||
{
|
{
|
||||||
HKEY hKey,hKey1;
|
HKEY hKey,hKey1;
|
||||||
|
@ -181,7 +181,7 @@ void test2(void)
|
||||||
DWORD Result;
|
DWORD Result;
|
||||||
dprintf("NtCreateKey volatile: \n");
|
dprintf("NtCreateKey volatile: \n");
|
||||||
dprintf(" \\Registry\\Machine\\Software\\test2reactos: ");
|
dprintf(" \\Registry\\Machine\\Software\\test2reactos: ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
|
@ -190,31 +190,31 @@ void test2(void)
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
do_enumeratekey(L"\\Registry\\Machine\\Software");
|
do_enumeratekey(L"\\Registry\\Machine\\Software");
|
||||||
dprintf(" ...\\test2 :");
|
dprintf(" ...\\test2 :");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey ( &hKey1, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey1, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
,0,NULL,REG_OPTION_VOLATILE,NULL);
|
,0,NULL,REG_OPTION_VOLATILE,NULL);
|
||||||
dprintf("\t\t\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\t\t\tStatus=%x\n",Status);
|
||||||
dprintf(" ...\\TestVolatile :");
|
dprintf(" ...\\TestVolatile :");
|
||||||
RtlInitUnicodeString(&KeyName, L"TestVolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"TestVolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, hKey1, NULL);
|
, hKey1, NULL);
|
||||||
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
,0,NULL,REG_OPTION_VOLATILE,NULL);
|
,0,NULL,REG_OPTION_VOLATILE,NULL);
|
||||||
dprintf("\t\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey1);
|
NtClose(hKey1);
|
||||||
RtlInitUnicodeString(&ValueName, L"TestREG_SZ");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestREG_SZ");
|
||||||
dprintf("NtSetValueKey reg_sz: ");
|
dprintf("NtSetValueKey reg_sz: ");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"Test Reg_sz",24);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"Test Reg_sz",24);
|
||||||
dprintf("\t\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\t\tStatus=%x\n",Status);
|
||||||
RtlInitUnicodeString(&ValueName, L"TestDWORD");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestDWORD");
|
||||||
dprintf("NtSetValueKey reg_dword: ");
|
dprintf("NtSetValueKey reg_dword: ");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_DWORD,(PVOID)"reac",4);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_DWORD,(PVOID)"reac",4);
|
||||||
dprintf("\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
dprintf("NtOpenKey \\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile : ");
|
dprintf("NtOpenKey \\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -250,7 +250,7 @@ void test2(void)
|
||||||
dprintf("delete \\Registry\\Machine\\software\\test2reactos ?");
|
dprintf("delete \\Registry\\Machine\\software\\test2reactos ?");
|
||||||
ReadConsoleA(InputHandle, Buffer, 3, &Result, NULL) ;
|
ReadConsoleA(InputHandle, Buffer, 3, &Result, NULL) ;
|
||||||
if (Buffer[0] != 'y' && Buffer[0] != 'Y') return;
|
if (Buffer[0] != 'y' && Buffer[0] != 'Y') return;
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2\\TestVolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -263,7 +263,7 @@ void test2(void)
|
||||||
Status=NtDeleteKey(hKey);
|
Status=NtDeleteKey(hKey);
|
||||||
dprintf("\t\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\t\tStatus =%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos\\test2");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -276,7 +276,7 @@ void test2(void)
|
||||||
Status=NtDeleteKey(hKey);
|
Status=NtDeleteKey(hKey);
|
||||||
dprintf("\t\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\t\tStatus =%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test2reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -303,7 +303,7 @@ void test3(void)
|
||||||
DWORD Result;
|
DWORD Result;
|
||||||
dprintf("NtCreateKey non volatile: \n");
|
dprintf("NtCreateKey non volatile: \n");
|
||||||
dprintf(" \\Registry\\Machine\\Software\\test3reactos: ");
|
dprintf(" \\Registry\\Machine\\Software\\test3reactos: ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
|
@ -316,7 +316,7 @@ void test3(void)
|
||||||
dprintf("\t\tStatus=%x\n",Status);
|
dprintf("\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
dprintf(" ...\\test3 :");
|
dprintf(" ...\\test3 :");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
|
@ -327,24 +327,24 @@ void test3(void)
|
||||||
dprintf("\t\tStatus=%x\n",Status);
|
dprintf("\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
dprintf(" ...\\testNonVolatile :");
|
dprintf(" ...\\testNonVolatile :");
|
||||||
RtlInitUnicodeString(&KeyName, L"TestNonVolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"TestNonVolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, hKey1, NULL);
|
, hKey1, NULL);
|
||||||
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey ( &hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
,0,NULL,REG_OPTION_NON_VOLATILE,NULL);
|
,0,NULL,REG_OPTION_NON_VOLATILE,NULL);
|
||||||
dprintf("\t\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey1);
|
NtClose(hKey1);
|
||||||
RtlInitUnicodeString(&ValueName, L"TestREG_SZ");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestREG_SZ");
|
||||||
dprintf("NtSetValueKey reg_sz: ");
|
dprintf("NtSetValueKey reg_sz: ");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"Test Reg_sz",24);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"Test Reg_sz",24);
|
||||||
dprintf("\t\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\t\tStatus=%x\n",Status);
|
||||||
RtlInitUnicodeString(&ValueName, L"TestDWORD");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestDWORD");
|
||||||
dprintf("NtSetValueKey reg_dword: ");
|
dprintf("NtSetValueKey reg_dword: ");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_DWORD,(PVOID)"reac",4);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_DWORD,(PVOID)"reac",4);
|
||||||
dprintf("\t\t\tStatus=%x\n",Status);
|
dprintf("\t\t\tStatus=%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
dprintf("NtOpenKey \\Registry\\Machine\\Software\\test3reactos\\test3\\testNonVolatile : ");
|
dprintf("NtOpenKey \\Registry\\Machine\\Software\\test3reactos\\test3\\testNonVolatile : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3\\testNonVolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3\\testNonVolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -380,7 +380,7 @@ void test3(void)
|
||||||
dprintf("delete \\Registry\\Machine\\software\\test3reactos ?");
|
dprintf("delete \\Registry\\Machine\\software\\test3reactos ?");
|
||||||
ReadConsoleA(InputHandle, Buffer, 3, &Result, NULL) ;
|
ReadConsoleA(InputHandle, Buffer, 3, &Result, NULL) ;
|
||||||
if (Buffer[0] != 'y' && Buffer[0] != 'Y') return;
|
if (Buffer[0] != 'y' && Buffer[0] != 'Y') return;
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3\\testNonvolatile");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3\\testNonvolatile");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -392,7 +392,7 @@ void test3(void)
|
||||||
dprintf("NtDeleteKey : ");
|
dprintf("NtDeleteKey : ");
|
||||||
Status=NtDeleteKey(hKey);
|
Status=NtDeleteKey(hKey);
|
||||||
dprintf("\t\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\t\tStatus =%x\n",Status);
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos\\test3");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -405,7 +405,7 @@ void test3(void)
|
||||||
Status=NtDeleteKey(hKey);
|
Status=NtDeleteKey(hKey);
|
||||||
dprintf("\t\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\t\tStatus =%x\n",Status);
|
||||||
NtClose(hKey);
|
NtClose(hKey);
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\Software\\test3reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -595,7 +595,7 @@ void test5(void)
|
||||||
|
|
||||||
dprintf("NtOpenKey : \n");
|
dprintf("NtOpenKey : \n");
|
||||||
dprintf(" \\Registry\\Machine\\Software\\reactos : ");
|
dprintf(" \\Registry\\Machine\\Software\\reactos : ");
|
||||||
RtlInitUnicodeString(&KeyName,L"\\Registry\\Machine\\Software\\reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName,L"\\Registry\\Machine\\Software\\reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status=NtOpenKey( &hKey, KEY_ALL_ACCESS, &ObjectAttributes);
|
Status=NtOpenKey( &hKey, KEY_ALL_ACCESS, &ObjectAttributes);
|
||||||
|
@ -622,7 +622,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Create target key\n");
|
dprintf("Create target key\n");
|
||||||
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Reactos\n");
|
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Reactos\n");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Reactos");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Reactos");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey(&hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey(&hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
|
@ -633,7 +633,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Create target value\n");
|
dprintf("Create target value\n");
|
||||||
dprintf(" Value: TestValue = 'Test String'\n");
|
dprintf(" Value: TestValue = 'Test String'\n");
|
||||||
RtlInitUnicodeString(&ValueName, L"TestValue");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestValue");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"TestString",22);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_SZ,(PVOID)L"TestString",22);
|
||||||
dprintf(" NtSetValueKey() called (Status %lx)\n",Status);
|
dprintf(" NtSetValueKey() called (Status %lx)\n",Status);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
|
@ -645,7 +645,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Create link key\n");
|
dprintf("Create link key\n");
|
||||||
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE | OBJ_OPENLINK,
|
OBJ_CASE_INSENSITIVE | OBJ_OPENLINK,
|
||||||
|
@ -664,7 +664,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Create link value\n");
|
dprintf("Create link value\n");
|
||||||
dprintf(" Value: SymbolicLinkValue = '\\Registry\\Machine\\SOFTWARE\\Reactos'\n");
|
dprintf(" Value: SymbolicLinkValue = '\\Registry\\Machine\\SOFTWARE\\Reactos'\n");
|
||||||
RtlInitUnicodeString(&ValueName, L"SymbolicLinkValue");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"SymbolicLinkValue");
|
||||||
Status=NtSetValueKey(hKey,&ValueName,0,REG_LINK,(PVOID)L"\\Registry\\Machine\\SOFTWARE\\Reactos",68);
|
Status=NtSetValueKey(hKey,&ValueName,0,REG_LINK,(PVOID)L"\\Registry\\Machine\\SOFTWARE\\Reactos",68);
|
||||||
dprintf(" NtSetValueKey() called (Status %lx)\n",Status);
|
dprintf(" NtSetValueKey() called (Status %lx)\n",Status);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
|
@ -679,7 +679,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Open link key\n");
|
dprintf("Open link key\n");
|
||||||
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE | OBJ_OPENIF
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE | OBJ_OPENIF
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtCreateKey(&hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
Status = NtCreateKey(&hKey, KEY_ALL_ACCESS , &ObjectAttributes
|
||||||
|
@ -690,7 +690,7 @@ void test6(void)
|
||||||
|
|
||||||
dprintf("Query value\n");
|
dprintf("Query value\n");
|
||||||
dprintf(" Value: TestValue\n");
|
dprintf(" Value: TestValue\n");
|
||||||
RtlInitUnicodeString(&ValueName, L"TestValue");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"TestValue");
|
||||||
Status=NtQueryValueKey(hKey,
|
Status=NtQueryValueKey(hKey,
|
||||||
&ValueName,
|
&ValueName,
|
||||||
KeyValueFullInformation,
|
KeyValueFullInformation,
|
||||||
|
@ -729,7 +729,7 @@ void test7(void)
|
||||||
|
|
||||||
dprintf("Open link key\n");
|
dprintf("Open link key\n");
|
||||||
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
dprintf(" Key: \\Registry\\Machine\\SOFTWARE\\Test\n");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine\\SOFTWARE\\Test");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE | OBJ_OPENIF | OBJ_OPENLINK,
|
OBJ_CASE_INSENSITIVE | OBJ_OPENIF | OBJ_OPENLINK,
|
||||||
|
@ -750,7 +750,7 @@ void test7(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
dprintf("Delete link value\n");
|
dprintf("Delete link value\n");
|
||||||
RtlInitUnicodeString(&ValueName, L"SymbolicLinkValue");
|
RtlInitUnicodeStringFromLiteral(&ValueName, L"SymbolicLinkValue");
|
||||||
Status = NtDeleteValueKey(hKey,
|
Status = NtDeleteValueKey(hKey,
|
||||||
&ValueName);
|
&ValueName);
|
||||||
dprintf(" NtDeleteValueKey() called (Status %lx)\n",Status);
|
dprintf(" NtDeleteValueKey() called (Status %lx)\n",Status);
|
||||||
|
@ -801,7 +801,7 @@ void test8(void)
|
||||||
// dprintf("\t\t\t\tStatus =%x\n",Status);
|
// dprintf("\t\t\t\tStatus =%x\n",Status);
|
||||||
|
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyName,L"test5");
|
RtlInitUnicodeStringFromLiteral(&KeyName,L"test5");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtLoadKey(HKEY_LOCAL_MACHINE,&ObjectAttributes);
|
Status = NtLoadKey(HKEY_LOCAL_MACHINE,&ObjectAttributes);
|
||||||
|
@ -811,7 +811,7 @@ void test8(void)
|
||||||
dprintf("\t\t\t\tdwError =%x\n",dwError);
|
dprintf("\t\t\t\tdwError =%x\n",dwError);
|
||||||
|
|
||||||
dprintf("NtOpenKey \\Registry\\Machine : ");
|
dprintf("NtOpenKey \\Registry\\Machine : ");
|
||||||
RtlInitUnicodeString(&KeyName, L"\\Registry\\Machine");
|
RtlInitUnicodeStringFromLiteral(&KeyName, L"\\Registry\\Machine");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -819,7 +819,7 @@ void test8(void)
|
||||||
NULL);
|
NULL);
|
||||||
Status=NtOpenKey( &hKey, MAXIMUM_ALLOWED, &ObjectAttributes);
|
Status=NtOpenKey( &hKey, MAXIMUM_ALLOWED, &ObjectAttributes);
|
||||||
dprintf("\t\t\tStatus =%x\n",Status);
|
dprintf("\t\t\tStatus =%x\n",Status);
|
||||||
RtlInitUnicodeString(&KeyName,L"test5");
|
RtlInitUnicodeStringFromLiteral(&KeyName,L"test5");
|
||||||
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
InitializeObjectAttributes(&ObjectAttributes, &KeyName, OBJ_CASE_INSENSITIVE
|
||||||
, NULL, NULL);
|
, NULL, NULL);
|
||||||
Status = NtLoadKey(hKey,&ObjectAttributes);
|
Status = NtLoadKey(hKey,&ObjectAttributes);
|
||||||
|
|
|
@ -192,14 +192,13 @@ NTSTATUS PiceSendIoctl(PDEVICE_OBJECT Target, ULONG Ioctl,
|
||||||
BOOLEAN PatchKeyboardDriver(void)
|
BOOLEAN PatchKeyboardDriver(void)
|
||||||
{
|
{
|
||||||
PINTERNAL_I8042_HOOK_KEYBOARD phkData;
|
PINTERNAL_I8042_HOOK_KEYBOARD phkData;
|
||||||
UNICODE_STRING DevName;
|
//When we have i8042 driver this should be changed!!!!!!!
|
||||||
|
UNICODE_STRING DevName = UNICODE_STRING_INITIALIZER(L"\\Device\\Keyboard");
|
||||||
PDEVICE_OBJECT kbdDevice = NULL;
|
PDEVICE_OBJECT kbdDevice = NULL;
|
||||||
PFILE_OBJECT FO = NULL;
|
PFILE_OBJECT FO = NULL;
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
|
|
||||||
ENTER_FUNC();
|
ENTER_FUNC();
|
||||||
//When we have i8042 driver this should be changed!!!!!!!
|
|
||||||
RtlInitUnicodeString(&DevName, L"\\Device\\Keyboard");
|
|
||||||
|
|
||||||
//Get pointer to keyboard device
|
//Get pointer to keyboard device
|
||||||
if( !NT_SUCCESS( status = IoGetDeviceObjectPointer( &DevName, FILE_READ_ACCESS, &FO, &kbdDevice ) ) )
|
if( !NT_SUCCESS( status = IoGetDeviceObjectPointer( &DevName, FILE_READ_ACCESS, &FO, &kbdDevice ) ) )
|
||||||
|
|
|
@ -183,7 +183,7 @@ NTSTATUS STDCALL DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
//ei unimplemented DriverObject->MajorFunction[IRP_MJ_CLOSE] = pice_close;
|
//ei unimplemented DriverObject->MajorFunction[IRP_MJ_CLOSE] = pice_close;
|
||||||
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = pice_ioctl;
|
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = pice_ioctl;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Pice");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\Device\\Pice");
|
||||||
IoCreateDevice(DriverObject,
|
IoCreateDevice(DriverObject,
|
||||||
0,
|
0,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -193,7 +193,7 @@ NTSTATUS STDCALL DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
||||||
|
|
||||||
RtlInitUnicodeString(&SymlinkName, L"\\??\\Pice");
|
RtlInitUnicodeStringFromLiteral(&SymlinkName, L"\\??\\Pice");
|
||||||
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
return(STATUS_SUCCESS);
|
return(STATUS_SUCCESS);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: beep.c,v 1.11 2002/07/18 00:29:19 ekohl Exp $
|
/* $Id: beep.c,v 1.12 2002/08/20 20:37:04 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -240,8 +240,8 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
{
|
{
|
||||||
PDEVICE_EXTENSION DeviceExtension;
|
PDEVICE_EXTENSION DeviceExtension;
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Beep");
|
||||||
UNICODE_STRING SymlinkName;
|
UNICODE_STRING SymlinkName = UNICODE_STRING_INITIALIZER(L"\\??\\Beep");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("Beep Device Driver 0.0.3\n");
|
DPRINT("Beep Device Driver 0.0.3\n");
|
||||||
|
@ -253,8 +253,6 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = BeepDeviceControl;
|
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = BeepDeviceControl;
|
||||||
DriverObject->DriverUnload = BeepUnload;
|
DriverObject->DriverUnload = BeepUnload;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName,
|
|
||||||
L"\\Device\\Beep");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -278,8 +276,6 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
FALSE);
|
FALSE);
|
||||||
|
|
||||||
/* Create the dos device link */
|
/* Create the dos device link */
|
||||||
RtlInitUnicodeString(&SymlinkName,
|
|
||||||
L"\\??\\Beep");
|
|
||||||
IoCreateSymbolicLink(&SymlinkName,
|
IoCreateSymbolicLink(&SymlinkName,
|
||||||
&DeviceName);
|
&DeviceName);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: blue.c,v 1.32 2002/02/08 02:57:07 chorns Exp $
|
/* $Id: blue.c,v 1.33 2002/08/20 20:37:05 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -607,8 +607,8 @@ NTSTATUS STDCALL
|
||||||
DriverEntry (PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
DriverEntry (PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\BlueScreen");
|
||||||
UNICODE_STRING SymlinkName;
|
UNICODE_STRING SymlinkName = UNICODE_STRING_INITIALIZER(L"\\??\\BlueScreen");
|
||||||
|
|
||||||
DPRINT ("Screen Driver 0.0.6\n");
|
DPRINT ("Screen Driver 0.0.6\n");
|
||||||
|
|
||||||
|
@ -618,7 +618,6 @@ DriverEntry (PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
DriverObject->MajorFunction[IRP_MJ_WRITE] = ScrWrite;
|
DriverObject->MajorFunction[IRP_MJ_WRITE] = ScrWrite;
|
||||||
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL ] = ScrIoControl;
|
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL ] = ScrIoControl;
|
||||||
|
|
||||||
RtlInitUnicodeString (&DeviceName, L"\\Device\\BlueScreen");
|
|
||||||
IoCreateDevice (DriverObject,
|
IoCreateDevice (DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -627,7 +626,6 @@ DriverEntry (PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
TRUE,
|
TRUE,
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
|
|
||||||
RtlInitUnicodeString (&SymlinkName, L"\\??\\BlueScreen");
|
|
||||||
IoCreateSymbolicLink (&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink (&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
return (STATUS_SUCCESS);
|
return (STATUS_SUCCESS);
|
||||||
|
|
|
@ -122,7 +122,7 @@ FloppyCreateController(PDRIVER_OBJECT DriverObject,
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* FIXME: Let's assume one drive and one controller for the moment */
|
/* FIXME: Let's assume one drive and one controller for the moment */
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Floppy0");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\Device\\Floppy0");
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(FLOPPY_DEVICE_EXTENSION),
|
sizeof(FLOPPY_DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: null.c,v 1.7 2002/04/29 23:06:42 hyperion Exp $
|
/* $Id: null.c,v 1.8 2002/08/20 20:37:05 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -113,7 +113,7 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
DriverObject->DriverUnload = NullUnload;
|
DriverObject->DriverUnload = NullUnload;
|
||||||
|
|
||||||
/* create null device */
|
/* create null device */
|
||||||
RtlInitUnicodeString(&wstrDeviceName, L"\\Device\\Null");
|
RtlInitUnicodeStringFromLiteral(&wstrDeviceName, L"\\Device\\Null");
|
||||||
|
|
||||||
nErrCode = IoCreateDevice
|
nErrCode = IoCreateDevice
|
||||||
(
|
(
|
||||||
|
@ -135,7 +135,7 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
pdoNullDevice->DeviceExtension = (PVOID)&nxNull;
|
pdoNullDevice->DeviceExtension = (PVOID)&nxNull;
|
||||||
|
|
||||||
/* create zero device */
|
/* create zero device */
|
||||||
RtlInitUnicodeString(&wstrDeviceName, L"\\Device\\Zero");
|
RtlInitUnicodeStringFromLiteral(&wstrDeviceName, L"\\Device\\Zero");
|
||||||
|
|
||||||
nErrCode = IoCreateDevice
|
nErrCode = IoCreateDevice
|
||||||
(
|
(
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: parallel.c,v 1.7 2002/02/08 02:57:08 chorns Exp $
|
/* $Id: parallel.c,v 1.8 2002/08/20 20:37:05 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -127,13 +127,11 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Parallel");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("Parallel Port Driver 0.0.1\n");
|
DPRINT("Parallel Port Driver 0.0.1\n");
|
||||||
|
|
||||||
RtlInitUnicodeString (&DeviceName,
|
|
||||||
L"\\Device\\Parallel");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
0,
|
0,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -83,7 +83,7 @@ NTSTATUS STDCALL RamdrvDispatchOpenClose(PDEVICE_OBJECT DeviceObject,
|
||||||
NTSTATUS STDCALL DriverEntry(IN PDRIVER_OBJECT DriverObject,
|
NTSTATUS STDCALL DriverEntry(IN PDRIVER_OBJECT DriverObject,
|
||||||
IN PUNICODE_STRING RegistryPath)
|
IN PUNICODE_STRING RegistryPath)
|
||||||
{
|
{
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Ramdisk");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
PRAMDRV_DEVICE_EXTENSION devext;
|
PRAMDRV_DEVICE_EXTENSION devext;
|
||||||
|
@ -109,7 +109,6 @@ NTSTATUS STDCALL DriverEntry(IN PDRIVER_OBJECT DriverObject,
|
||||||
|
|
||||||
|
|
||||||
// create device and symbolic link
|
// create device and symbolic link
|
||||||
RtlInitUnicodeString( &DeviceName, L"\\Device\\Ramdisk" );
|
|
||||||
Status = IoCreateDevice( DriverObject,
|
Status = IoCreateDevice( DriverObject,
|
||||||
sizeof( RAMDRV_DEVICE_EXTENSION ),
|
sizeof( RAMDRV_DEVICE_EXTENSION ),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -128,10 +127,10 @@ NTSTATUS STDCALL DriverEntry(IN PDRIVER_OBJECT DriverObject,
|
||||||
Status = STATUS_INSUFFICIENT_RESOURCES;
|
Status = STATUS_INSUFFICIENT_RESOURCES;
|
||||||
goto cleandevice;
|
goto cleandevice;
|
||||||
}
|
}
|
||||||
RtlInitUnicodeString( &LinkName, L"\\??\\Z:" );
|
RtlInitUnicodeStringFromLiteral( &LinkName, L"\\??\\Z:" );
|
||||||
IoCreateSymbolicLink( &LinkName, &DeviceName );
|
IoCreateSymbolicLink( &LinkName, &DeviceName );
|
||||||
|
|
||||||
RtlInitUnicodeString( &LinkName, L"\\Device\\Floppy0\\ramdisk.bz2" );
|
RtlInitUnicodeStringFromLiteral( &LinkName, L"\\Device\\Floppy0\\ramdisk.bz2" );
|
||||||
InitializeObjectAttributes( &objattr,
|
InitializeObjectAttributes( &objattr,
|
||||||
&LinkName,
|
&LinkName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -99,7 +99,7 @@ VOID VGAResetDevice(OUT PSTATUS_BLOCK StatusBlock)
|
||||||
char *vidmem;
|
char *vidmem;
|
||||||
HANDLE Event;
|
HANDLE Event;
|
||||||
OBJECT_ATTRIBUTES Attr;
|
OBJECT_ATTRIBUTES Attr;
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name = UNICODE_STRING_INITIALIZER(L"\\TextConsoleRefreshEvent");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
VIDEO_X86_BIOS_ARGUMENTS vxba;
|
VIDEO_X86_BIOS_ARGUMENTS vxba;
|
||||||
VP_STATUS vps;
|
VP_STATUS vps;
|
||||||
|
@ -114,7 +114,6 @@ VOID VGAResetDevice(OUT PSTATUS_BLOCK StatusBlock)
|
||||||
memset(&vxba, 0, sizeof(vxba));
|
memset(&vxba, 0, sizeof(vxba));
|
||||||
vxba.Eax = 0x1112;
|
vxba.Eax = 0x1112;
|
||||||
vps = VideoPortInt10(NULL, &vxba);
|
vps = VideoPortInt10(NULL, &vxba);
|
||||||
RtlInitUnicodeString( &Name, L"\\TextConsoleRefreshEvent" );
|
|
||||||
InitializeObjectAttributes( &Attr, &Name, 0, 0, 0 );
|
InitializeObjectAttributes( &Attr, &Name, 0, 0, 0 );
|
||||||
Status = ZwOpenEvent( &Event, STANDARD_RIGHTS_ALL, &Attr );
|
Status = ZwOpenEvent( &Event, STANDARD_RIGHTS_ALL, &Attr );
|
||||||
if( !NT_SUCCESS( Status ) )
|
if( !NT_SUCCESS( Status ) )
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: cdfs.c,v 1.5 2002/05/15 18:01:30 ekohl Exp $
|
/* $Id: cdfs.c,v 1.6 2002/08/20 20:37:06 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -56,12 +56,10 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Cdfs");
|
||||||
|
|
||||||
DPRINT("CDFS 0.0.2\n");
|
DPRINT("CDFS 0.0.2\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName,
|
|
||||||
L"\\Cdfs");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(CDFS_GLOBAL_DATA),
|
sizeof(CDFS_GLOBAL_DATA),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -154,14 +154,12 @@ DriverEntry(PDRIVER_OBJECT _DriverObject,
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
NTSTATUS ret;
|
NTSTATUS ret;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Ext2Fsd");
|
||||||
|
|
||||||
DbgPrint("Ext2 FSD 0.0.1\n");
|
DbgPrint("Ext2 FSD 0.0.1\n");
|
||||||
|
|
||||||
DriverObject = _DriverObject;
|
DriverObject = _DriverObject;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName,
|
|
||||||
L"\\Device\\Ext2Fsd");
|
|
||||||
ret = IoCreateDevice(DriverObject,
|
ret = IoCreateDevice(DriverObject,
|
||||||
0,
|
0,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: cdfs.c,v 1.4 2002/06/12 23:35:55 ekohl Exp $
|
/* $Id: cdfs.c,v 1.5 2002/08/20 20:37:06 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -119,7 +119,7 @@ FsRecCdfsFsControl(IN PDEVICE_OBJECT DeviceObject,
|
||||||
|
|
||||||
case IRP_MN_LOAD_FILE_SYSTEM:
|
case IRP_MN_LOAD_FILE_SYSTEM:
|
||||||
DPRINT("Cdfs: IRP_MN_LOAD_FILE_SYSTEM\n");
|
DPRINT("Cdfs: IRP_MN_LOAD_FILE_SYSTEM\n");
|
||||||
RtlInitUnicodeString(&RegistryPath,
|
RtlInitUnicodeStringFromLiteral(&RegistryPath,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\Cdfs");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\Cdfs");
|
||||||
Status = ZwLoadDriver(&RegistryPath);
|
Status = ZwLoadDriver(&RegistryPath);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: fat.c,v 1.3 2002/06/12 23:35:55 ekohl Exp $
|
/* $Id: fat.c,v 1.4 2002/08/20 20:37:06 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -117,7 +117,7 @@ FsRecVfatFsControl(IN PDEVICE_OBJECT DeviceObject,
|
||||||
|
|
||||||
case IRP_MN_LOAD_FILE_SYSTEM:
|
case IRP_MN_LOAD_FILE_SYSTEM:
|
||||||
DPRINT("FAT: IRP_MN_LOAD_FILE_SYSTEM\n");
|
DPRINT("FAT: IRP_MN_LOAD_FILE_SYSTEM\n");
|
||||||
RtlInitUnicodeString(&RegistryPath,
|
RtlInitUnicodeStringFromLiteral(&RegistryPath,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\Vfatfs");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\Vfatfs");
|
||||||
Status = ZwLoadDriver(&RegistryPath);
|
Status = ZwLoadDriver(&RegistryPath);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: ntfs.c,v 1.1 2002/06/25 22:23:06 ekohl Exp $
|
/* $Id: ntfs.c,v 1.2 2002/08/20 20:37:06 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -55,12 +55,10 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Ntfs");
|
||||||
|
|
||||||
DPRINT("NTFS 0.0.1\n");
|
DPRINT("NTFS 0.0.1\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName,
|
|
||||||
L"\\Ntfs");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(NTFS_GLOBAL_DATA),
|
sizeof(NTFS_GLOBAL_DATA),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: template.c,v 1.3 2002/05/23 09:52:56 ekohl Exp $
|
/* $Id: template.c,v 1.4 2002/08/20 20:37:07 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -249,14 +249,12 @@ DriverEntry(PDRIVER_OBJECT _DriverObject,
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\BareFsd");
|
||||||
|
|
||||||
DbgPrint("Bare FSD Template 0.0.1\n");
|
DbgPrint("Bare FSD Template 0.0.1\n");
|
||||||
|
|
||||||
DriverObject = _DriverObject;
|
DriverObject = _DriverObject;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName,
|
|
||||||
L"\\Device\\BareFsd");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
0,
|
0,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: iface.c,v 1.64 2002/08/14 20:58:31 dwelch Exp $
|
/* $Id: iface.c,v 1.65 2002/08/20 20:37:07 hyperion Exp $
|
||||||
*
|
*
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
* FILE: services/fs/vfat/iface.c
|
* FILE: services/fs/vfat/iface.c
|
||||||
|
@ -51,10 +51,9 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Fat");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Fat");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(VFAT_GLOBAL_DATA),
|
sizeof(VFAT_GLOBAL_DATA),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -831,8 +831,8 @@ NTSTATUS STDCALL DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Keyboard");
|
||||||
UNICODE_STRING SymlinkName;
|
UNICODE_STRING SymlinkName = UNICODE_STRING_INITIALIZER(L"\\??\\Keyboard");
|
||||||
|
|
||||||
DPRINT("Keyboard Driver 0.0.4\n");
|
DPRINT("Keyboard Driver 0.0.4\n");
|
||||||
|
|
||||||
|
@ -843,7 +843,6 @@ NTSTATUS STDCALL DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
|
|
||||||
DriverObject->DriverStartIo = KbdStartIo;
|
DriverObject->DriverStartIo = KbdStartIo;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Keyboard");
|
|
||||||
IoCreateDevice(DriverObject,
|
IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -857,8 +856,6 @@ NTSTATUS STDCALL DriverEntry(PDRIVER_OBJECT DriverObject,
|
||||||
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
||||||
InitializeKeyboard( DeviceObject );
|
InitializeKeyboard( DeviceObject );
|
||||||
|
|
||||||
|
|
||||||
RtlInitUnicodeString(&SymlinkName, L"\\??\\Keyboard");
|
|
||||||
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
return(STATUS_SUCCESS);
|
return(STATUS_SUCCESS);
|
||||||
|
|
|
@ -90,7 +90,7 @@ NTSTATUS ConnectMousePortDriver(PDEVICE_OBJECT ClassDeviceObject)
|
||||||
PDEVICE_OBJECT PortDeviceObject = NULL;
|
PDEVICE_OBJECT PortDeviceObject = NULL;
|
||||||
PFILE_OBJECT FileObject = NULL;
|
PFILE_OBJECT FileObject = NULL;
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
UNICODE_STRING PortName;
|
UNICODE_STRING PortName = UNICODE_STRING_INITIALIZER(L"\\Device\\Mouse");
|
||||||
IO_STATUS_BLOCK ioStatus;
|
IO_STATUS_BLOCK ioStatus;
|
||||||
KEVENT event;
|
KEVENT event;
|
||||||
PIRP irp;
|
PIRP irp;
|
||||||
|
@ -102,7 +102,6 @@ NTSTATUS ConnectMousePortDriver(PDEVICE_OBJECT ClassDeviceObject)
|
||||||
// Get the port driver's DeviceObject
|
// Get the port driver's DeviceObject
|
||||||
// FIXME: The name might change.. find a way to be more dynamic?
|
// FIXME: The name might change.. find a way to be more dynamic?
|
||||||
|
|
||||||
RtlInitUnicodeString(&PortName, L"\\Device\\Mouse");
|
|
||||||
status = IoGetDeviceObjectPointer(&PortName, FILE_READ_ATTRIBUTES, &FileObject, &PortDeviceObject);
|
status = IoGetDeviceObjectPointer(&PortName, FILE_READ_ATTRIBUTES, &FileObject, &PortDeviceObject);
|
||||||
|
|
||||||
if(status != STATUS_SUCCESS)
|
if(status != STATUS_SUCCESS)
|
||||||
|
@ -263,8 +262,8 @@ NTSTATUS STDCALL
|
||||||
DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
{
|
{
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\MouseClass");
|
||||||
UNICODE_STRING SymlinkName;
|
UNICODE_STRING SymlinkName = UNICODE_STRING_INITIALIZER(L"\\??\\MouseClass");
|
||||||
|
|
||||||
DriverObject->MajorFunction[IRP_MJ_CREATE] = MouseClassDispatch;
|
DriverObject->MajorFunction[IRP_MJ_CREATE] = MouseClassDispatch;
|
||||||
// DriverObject->MajorFunction[IRP_MJ_CLOSE] = MouseClassDispatch;
|
// DriverObject->MajorFunction[IRP_MJ_CLOSE] = MouseClassDispatch;
|
||||||
|
@ -272,7 +271,6 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = MouseClassInternalDeviceControl; // to get GDI callback
|
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = MouseClassInternalDeviceControl; // to get GDI callback
|
||||||
// DriverObject->DriverStartIo = MouseClassStartIo;
|
// DriverObject->DriverStartIo = MouseClassStartIo;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\MouseClass");
|
|
||||||
IoCreateDevice(DriverObject,
|
IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -282,7 +280,6 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
||||||
|
|
||||||
RtlInitUnicodeString(&SymlinkName, L"\\??\\MouseClass");
|
|
||||||
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
return ConnectMousePortDriver(DeviceObject);
|
return ConnectMousePortDriver(DeviceObject);
|
||||||
|
|
|
@ -171,7 +171,8 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = PS2MouseInternalDeviceControl;
|
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = PS2MouseInternalDeviceControl;
|
||||||
DriverObject->DriverStartIo = PS2MouseStartIo;
|
DriverObject->DriverStartIo = PS2MouseStartIo;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Mouse"); // FIXME: find correct device name
|
RtlInitUnicodeStringFromLiteral(&DeviceName,
|
||||||
|
L"\\Device\\Mouse"); // FIXME: find correct device name
|
||||||
IoCreateDevice(DriverObject,
|
IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -181,7 +182,8 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
||||||
|
|
||||||
RtlInitUnicodeString(&SymlinkName, L"\\??\\Mouse"); // FIXME: find correct device name
|
RtlInitUnicodeStringFromLiteral(&SymlinkName,
|
||||||
|
L"\\??\\Mouse"); // FIXME: find correct device name
|
||||||
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
DeviceExtension = DeviceObject->DeviceExtension;
|
DeviceExtension = DeviceObject->DeviceExtension;
|
||||||
|
|
|
@ -350,7 +350,8 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = SerialMouseInternalDeviceControl;
|
DriverObject->MajorFunction[IRP_MJ_INTERNAL_DEVICE_CONTROL] = SerialMouseInternalDeviceControl;
|
||||||
DriverObject->DriverStartIo = SerialMouseStartIo;
|
DriverObject->DriverStartIo = SerialMouseStartIo;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Mouse"); // FIXME: find correct device name
|
RtlInitUnicodeStringFromLiteral(&DeviceName,
|
||||||
|
L"\\Device\\Mouse"); // FIXME: find correct device name
|
||||||
IoCreateDevice(DriverObject,
|
IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -360,7 +361,8 @@ DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath)
|
||||||
&DeviceObject);
|
&DeviceObject);
|
||||||
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
DeviceObject->Flags = DeviceObject->Flags | DO_BUFFERED_IO;
|
||||||
|
|
||||||
RtlInitUnicodeString(&SymlinkName, L"\\??\\Mouse"); // FIXME: find correct device name
|
RtlInitUnicodeStringFromLiteral(&SymlinkName,
|
||||||
|
L"\\??\\Mouse"); // FIXME: find correct device name
|
||||||
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
IoCreateSymbolicLink(&SymlinkName, &DeviceName);
|
||||||
|
|
||||||
DeviceExtension = DeviceObject->DeviceExtension;
|
DeviceExtension = DeviceObject->DeviceExtension;
|
||||||
|
|
|
@ -146,10 +146,9 @@ DriverEntry(
|
||||||
{
|
{
|
||||||
PDEVICE_EXTENSION DeviceExt;
|
PDEVICE_EXTENSION DeviceExt;
|
||||||
PDEVICE_OBJECT DeviceObject;
|
PDEVICE_OBJECT DeviceObject;
|
||||||
UNICODE_STRING DeviceName;
|
UNICODE_STRING DeviceName = UNICODE_STRING_INITIALIZER(L"\\Device\\Afd");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Afd");
|
|
||||||
Status = IoCreateDevice(DriverObject,
|
Status = IoCreateDevice(DriverObject,
|
||||||
sizeof(DEVICE_EXTENSION),
|
sizeof(DEVICE_EXTENSION),
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -1030,7 +1030,7 @@ NdisMRegisterMiniport(
|
||||||
|
|
||||||
/* Create the device object for this adapter */
|
/* Create the device object for this adapter */
|
||||||
/* FIXME: Use GUIDs */
|
/* FIXME: Use GUIDs */
|
||||||
RtlInitUnicodeString(&Adapter->DeviceName, L"\\Device\\ne2000");
|
RtlInitUnicodeStringFromLiteral(&Adapter->DeviceName, L"\\Device\\ne2000");
|
||||||
Status = IoCreateDevice(Miniport->DriverObject,
|
Status = IoCreateDevice(Miniport->DriverObject,
|
||||||
0,
|
0,
|
||||||
&Adapter->DeviceName,
|
&Adapter->DeviceName,
|
||||||
|
|
|
@ -717,7 +717,7 @@ DriverEntry(
|
||||||
/* FIXME: Create symbolic links in Win32 namespace */
|
/* FIXME: Create symbolic links in Win32 namespace */
|
||||||
|
|
||||||
/* Create IP device object */
|
/* Create IP device object */
|
||||||
RtlInitUnicodeString(&strDeviceName, DD_IP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&strDeviceName, DD_IP_DEVICE_NAME);
|
||||||
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
||||||
FILE_DEVICE_NETWORK, 0, FALSE, &IPDeviceObject);
|
FILE_DEVICE_NETWORK, 0, FALSE, &IPDeviceObject);
|
||||||
if (!NT_SUCCESS(Status)) {
|
if (!NT_SUCCESS(Status)) {
|
||||||
|
@ -726,7 +726,7 @@ DriverEntry(
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Create RawIP device object */
|
/* Create RawIP device object */
|
||||||
RtlInitUnicodeString(&strDeviceName, DD_RAWIP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&strDeviceName, DD_RAWIP_DEVICE_NAME);
|
||||||
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
||||||
FILE_DEVICE_NETWORK, 0, FALSE, &RawIPDeviceObject);
|
FILE_DEVICE_NETWORK, 0, FALSE, &RawIPDeviceObject);
|
||||||
if (!NT_SUCCESS(Status)) {
|
if (!NT_SUCCESS(Status)) {
|
||||||
|
@ -736,7 +736,7 @@ DriverEntry(
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Create UDP device object */
|
/* Create UDP device object */
|
||||||
RtlInitUnicodeString(&strDeviceName, DD_UDP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&strDeviceName, DD_UDP_DEVICE_NAME);
|
||||||
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
||||||
FILE_DEVICE_NETWORK, 0, FALSE, &UDPDeviceObject);
|
FILE_DEVICE_NETWORK, 0, FALSE, &UDPDeviceObject);
|
||||||
if (!NT_SUCCESS(Status)) {
|
if (!NT_SUCCESS(Status)) {
|
||||||
|
@ -746,7 +746,7 @@ DriverEntry(
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Create TCP device object */
|
/* Create TCP device object */
|
||||||
RtlInitUnicodeString(&strDeviceName, DD_TCP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&strDeviceName, DD_TCP_DEVICE_NAME);
|
||||||
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
Status = IoCreateDevice(DriverObject, 0, &strDeviceName,
|
||||||
FILE_DEVICE_NETWORK, 0, FALSE, &TCPDeviceObject);
|
FILE_DEVICE_NETWORK, 0, FALSE, &TCPDeviceObject);
|
||||||
if (!NT_SUCCESS(Status)) {
|
if (!NT_SUCCESS(Status)) {
|
||||||
|
|
|
@ -292,18 +292,18 @@ WSHOpenSocket2(
|
||||||
|
|
||||||
switch (*SocketType) {
|
switch (*SocketType) {
|
||||||
case SOCK_STREAM:
|
case SOCK_STREAM:
|
||||||
RtlInitUnicodeString(&String, DD_TCP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&String, DD_TCP_DEVICE_NAME);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case SOCK_DGRAM:
|
case SOCK_DGRAM:
|
||||||
RtlInitUnicodeString(&String, DD_UDP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&String, DD_UDP_DEVICE_NAME);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case SOCK_RAW:
|
case SOCK_RAW:
|
||||||
if ((*Protocol < 0) || (*Protocol > 255))
|
if ((*Protocol < 0) || (*Protocol > 255))
|
||||||
return WSAEINVAL;
|
return WSAEINVAL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&String, DD_RAW_IP_DEVICE_NAME);
|
RtlInitUnicodeStringFromLiteral(&String, DD_RAW_IP_DEVICE_NAME);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: rtl.h,v 1.64 2002/08/18 18:50:25 hyperion Exp $
|
/* $Id: rtl.h,v 1.65 2002/08/20 20:37:08 hyperion Exp $
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1066,6 +1066,70 @@ RtlInitUnicodeString (
|
||||||
PCWSTR SourceString
|
PCWSTR SourceString
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/*
|
||||||
|
VOID
|
||||||
|
InitializeUnicodeString (
|
||||||
|
PUNICODE_STRING DestinationString,
|
||||||
|
USHORT Lenght,
|
||||||
|
USHORT MaximumLength,
|
||||||
|
PCWSTR Buffer
|
||||||
|
);
|
||||||
|
|
||||||
|
Initialize an UNICODE_STRING from its fields. Use when you know the values of
|
||||||
|
all the fields in advance
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define InitializeUnicodeString(__PDEST_STRING__,__LENGTH__,__MAXLENGTH__,__BUFFER__) \
|
||||||
|
{ \
|
||||||
|
(__PDEST_STRING__)->Length = (__LENGTH__); \
|
||||||
|
(__PDEST_STRING__)->MaximumLength = (__MAXLENGTH__); \
|
||||||
|
(__PDEST_STRING__)->Buffer = (__BUFFER__); \
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
VOID
|
||||||
|
RtlInitUnicodeStringFromLiteral (
|
||||||
|
PUNICODE_STRING DestinationString,
|
||||||
|
PCWSTR SourceString
|
||||||
|
);
|
||||||
|
|
||||||
|
Initialize an UNICODE_STRING from a wide string literal. WARNING: use only with
|
||||||
|
string literals and statically initialized arrays, it will calculate the wrong
|
||||||
|
length otherwise
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define RtlInitUnicodeStringFromLiteral(__PDEST_STRING__,__SOURCE_STRING__) \
|
||||||
|
InitializeUnicodeString( \
|
||||||
|
(__PDEST_STRING__), \
|
||||||
|
sizeof(__SOURCE_STRING__) - sizeof(WCHAR), \
|
||||||
|
sizeof(__SOURCE_STRING__), \
|
||||||
|
(__SOURCE_STRING__) \
|
||||||
|
)
|
||||||
|
|
||||||
|
/*
|
||||||
|
Static initializer for UNICODE_STRING variables. Usage:
|
||||||
|
|
||||||
|
UNICODE_STRING wstr = UNICODE_STRING_INITIALIZER(L"string");
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define UNICODE_STRING_INITIALIZER(__SOURCE_STRING__) \
|
||||||
|
{ \
|
||||||
|
sizeof((__SOURCE_STRING__)) - sizeof(WCHAR), \
|
||||||
|
sizeof((__SOURCE_STRING__)), \
|
||||||
|
(__SOURCE_STRING__) \
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Initializer for empty UNICODE_STRING variables. Usage:
|
||||||
|
|
||||||
|
UNICODE_STRING wstr = EMPTY_UNICODE_STRING;
|
||||||
|
|
||||||
|
*/
|
||||||
|
#define EMPTY_UNICODE_STRING {0, 0, NULL}
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
STDCALL
|
STDCALL
|
||||||
RtlInitializeBitMap (
|
RtlInitializeBitMap (
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: reg.c,v 1.14 2001/09/03 23:11:59 ekohl Exp $
|
/* $Id: reg.c,v 1.15 2002/08/20 20:37:09 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS system libraries
|
* PROJECT: ReactOS system libraries
|
||||||
|
@ -181,13 +181,10 @@ static NTSTATUS
|
||||||
OpenClassesRootKey(PHANDLE KeyHandle)
|
OpenClassesRootKey(PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES Attributes;
|
OBJECT_ATTRIBUTES Attributes;
|
||||||
UNICODE_STRING KeyName;
|
UNICODE_STRING KeyName = UNICODE_STRING_INITIALIZER(L"\\Registry\\Machine\\Software\\CLASSES");
|
||||||
|
|
||||||
DPRINT("OpenClassesRootKey()\n");
|
DPRINT("OpenClassesRootKey()\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyName,
|
|
||||||
L"\\Registry\\Machine\\Software\\CLASSES");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&Attributes,
|
InitializeObjectAttributes(&Attributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -204,13 +201,10 @@ static NTSTATUS
|
||||||
OpenLocalMachineKey(PHANDLE KeyHandle)
|
OpenLocalMachineKey(PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES Attributes;
|
OBJECT_ATTRIBUTES Attributes;
|
||||||
UNICODE_STRING KeyName;
|
UNICODE_STRING KeyName = UNICODE_STRING_INITIALIZER(L"\\Registry\\Machine");
|
||||||
|
|
||||||
DPRINT("OpenLocalMachineKey()\n");
|
DPRINT("OpenLocalMachineKey()\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyName,
|
|
||||||
L"\\Registry\\Machine");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&Attributes,
|
InitializeObjectAttributes(&Attributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -227,13 +221,10 @@ static NTSTATUS
|
||||||
OpenUsersKey(PHANDLE KeyHandle)
|
OpenUsersKey(PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES Attributes;
|
OBJECT_ATTRIBUTES Attributes;
|
||||||
UNICODE_STRING KeyName;
|
UNICODE_STRING KeyName = UNICODE_STRING_INITIALIZER(L"\\Registry\\User");
|
||||||
|
|
||||||
DPRINT("OpenUsersKey()\n");
|
DPRINT("OpenUsersKey()\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyName,
|
|
||||||
L"\\Registry\\User");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&Attributes,
|
InitializeObjectAttributes(&Attributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -250,13 +241,11 @@ static NTSTATUS
|
||||||
OpenCurrentConfigKey(PHANDLE KeyHandle)
|
OpenCurrentConfigKey(PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES Attributes;
|
OBJECT_ATTRIBUTES Attributes;
|
||||||
UNICODE_STRING KeyName;
|
UNICODE_STRING KeyName =
|
||||||
|
UNICODE_STRING_INITIALIZER(L"\\Registry\\Machine\\System\\CurrentControlSet\\Hardware Profiles\\Current");
|
||||||
|
|
||||||
DPRINT("OpenCurrentConfigKey()\n");
|
DPRINT("OpenCurrentConfigKey()\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyName,
|
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Hardware Profiles\\Current");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&Attributes,
|
InitializeObjectAttributes(&Attributes,
|
||||||
&KeyName,
|
&KeyName,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
@ -464,7 +453,6 @@ RegCreateKeyExW(HKEY hKey,
|
||||||
}
|
}
|
||||||
|
|
||||||
DPRINT("ParentKey %x\n", (ULONG)ParentKey);
|
DPRINT("ParentKey %x\n", (ULONG)ParentKey);
|
||||||
|
|
||||||
RtlInitUnicodeString (&ClassString, lpClass);
|
RtlInitUnicodeString (&ClassString, lpClass);
|
||||||
RtlInitUnicodeString (&SubKeyString, lpSubKey);
|
RtlInitUnicodeString (&SubKeyString, lpSubKey);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: curdir.c,v 1.28 2002/04/27 19:14:30 hbirr Exp $
|
/* $Id: curdir.c,v 1.29 2002/08/20 20:37:09 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS system libraries
|
* PROJECT: ReactOS system libraries
|
||||||
|
@ -209,7 +209,7 @@ GetTempPathW (
|
||||||
Value.MaximumLength = (nBufferLength - 1) * sizeof(WCHAR);
|
Value.MaximumLength = (nBufferLength - 1) * sizeof(WCHAR);
|
||||||
Value.Buffer = lpBuffer;
|
Value.Buffer = lpBuffer;
|
||||||
|
|
||||||
RtlInitUnicodeString (&Name,
|
RtlInitUnicodeStringFromLiteral (&Name,
|
||||||
L"TMP");
|
L"TMP");
|
||||||
|
|
||||||
Status = RtlQueryEnvironmentVariable_U (NULL,
|
Status = RtlQueryEnvironmentVariable_U (NULL,
|
||||||
|
@ -217,7 +217,7 @@ GetTempPathW (
|
||||||
&Value);
|
&Value);
|
||||||
if (!NT_SUCCESS(Status) && Status != STATUS_BUFFER_TOO_SMALL)
|
if (!NT_SUCCESS(Status) && Status != STATUS_BUFFER_TOO_SMALL)
|
||||||
{
|
{
|
||||||
RtlInitUnicodeString (&Name,
|
RtlInitUnicodeStringFromLiteral (&Name,
|
||||||
L"TEMP");
|
L"TEMP");
|
||||||
|
|
||||||
Status = RtlQueryEnvironmentVariable_U (NULL,
|
Status = RtlQueryEnvironmentVariable_U (NULL,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: dllmain.c,v 1.20 2002/04/26 13:07:03 ekohl Exp $
|
/* $Id: dllmain.c,v 1.21 2002/08/20 20:37:10 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS system libraries
|
* PROJECT: ReactOS system libraries
|
||||||
|
@ -43,12 +43,9 @@ static NTSTATUS
|
||||||
OpenBaseDirectory(PHANDLE DirHandle)
|
OpenBaseDirectory(PHANDLE DirHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name = UNICODE_STRING_INITIALIZER(L"\\BaseNamedObjects");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&Name,
|
|
||||||
L"\\BaseNamedObjects");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&Name,
|
&Name,
|
||||||
OBJ_PERMANENT,
|
OBJ_PERMANENT,
|
||||||
|
|
|
@ -103,7 +103,7 @@ NTSTATUS OpenSocket(
|
||||||
|
|
||||||
AFD_DbgPrint(MAX_TRACE, ("EaInfo at (0x%X) EaLength is (%d).\n", (UINT)EaInfo, (INT)EaLength));
|
AFD_DbgPrint(MAX_TRACE, ("EaInfo at (0x%X) EaLength is (%d).\n", (UINT)EaInfo, (INT)EaLength));
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Afd");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\Device\\Afd");
|
||||||
InitializeObjectAttributes(
|
InitializeObjectAttributes(
|
||||||
&ObjectAttributes,
|
&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
@ -658,7 +658,7 @@ NTSTATUS OpenCommandChannel(
|
||||||
SocketInfo = (PAFD_SOCKET_INFORMATION)((ULONG_PTR)EaInfo->EaName + AFD_SOCKET_LENGTH);
|
SocketInfo = (PAFD_SOCKET_INFORMATION)((ULONG_PTR)EaInfo->EaName + AFD_SOCKET_LENGTH);
|
||||||
SocketInfo->CommandChannel = TRUE;
|
SocketInfo->CommandChannel = TRUE;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\Device\\Afd");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\Device\\Afd");
|
||||||
InitializeObjectAttributes(
|
InitializeObjectAttributes(
|
||||||
&ObjectAttributes,
|
&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: lpc.c,v 1.5 2002/02/02 17:15:22 phreak Exp $
|
/* $Id: lpc.c,v 1.6 2002/08/20 20:37:10 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -131,7 +131,7 @@ CsrClientConnectToServer(VOID)
|
||||||
{
|
{
|
||||||
return(Status);
|
return(Status);
|
||||||
}
|
}
|
||||||
RtlInitUnicodeString(&PortName, L"\\Windows\\ApiPort");
|
RtlInitUnicodeStringFromLiteral(&PortName, L"\\Windows\\ApiPort");
|
||||||
ConnectInfoLength = 0;
|
ConnectInfoLength = 0;
|
||||||
LpcWrite.Length = sizeof(LPC_SECTION_WRITE);
|
LpcWrite.Length = sizeof(LPC_SECTION_WRITE);
|
||||||
LpcWrite.SectionHandle = CsrSectionHandle;
|
LpcWrite.SectionHandle = CsrSectionHandle;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: debug.c,v 1.3 2001/08/03 17:17:16 ekohl Exp $
|
/* $Id: debug.c,v 1.4 2002/08/20 20:37:10 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -77,12 +77,9 @@ DbgSsInitialize(HANDLE ReplyPort,
|
||||||
ULONG Unknown3)
|
ULONG Unknown3)
|
||||||
{
|
{
|
||||||
SECURITY_QUALITY_OF_SERVICE Qos;
|
SECURITY_QUALITY_OF_SERVICE Qos;
|
||||||
UNICODE_STRING PortName;
|
UNICODE_STRING PortName = UNICODE_STRING_INITIALIZER(L"\\DbgSsApiPort");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString (&PortName,
|
|
||||||
L"\\DbgSsApiPort");
|
|
||||||
|
|
||||||
Qos.Length = sizeof(SECURITY_QUALITY_OF_SERVICE);
|
Qos.Length = sizeof(SECURITY_QUALITY_OF_SERVICE);
|
||||||
Qos.ImpersonationLevel = SecurityIdentification;
|
Qos.ImpersonationLevel = SecurityIdentification;
|
||||||
Qos.ContextTrackingMode = SECURITY_DYNAMIC_TRACKING;
|
Qos.ContextTrackingMode = SECURITY_DYNAMIC_TRACKING;
|
||||||
|
@ -123,16 +120,13 @@ NTSTATUS STDCALL
|
||||||
DbgUiConnectToDbg(VOID)
|
DbgUiConnectToDbg(VOID)
|
||||||
{
|
{
|
||||||
SECURITY_QUALITY_OF_SERVICE Qos;
|
SECURITY_QUALITY_OF_SERVICE Qos;
|
||||||
UNICODE_STRING PortName;
|
UNICODE_STRING PortName = UNICODE_STRING_INITIALIZER(L"\\DbgUiApiPort");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
PTEB Teb;
|
PTEB Teb;
|
||||||
ULONG InfoSize;
|
ULONG InfoSize;
|
||||||
|
|
||||||
Teb = NtCurrentTeb ();
|
Teb = NtCurrentTeb ();
|
||||||
|
|
||||||
RtlInitUnicodeString (&PortName,
|
|
||||||
L"\\DbgUiApiPort");
|
|
||||||
|
|
||||||
Qos.Length = sizeof(SECURITY_QUALITY_OF_SERVICE);
|
Qos.Length = sizeof(SECURITY_QUALITY_OF_SERVICE);
|
||||||
Qos.ImpersonationLevel = SecurityIdentification;
|
Qos.ImpersonationLevel = SecurityIdentification;
|
||||||
Qos.ContextTrackingMode = SECURITY_DYNAMIC_TRACKING;
|
Qos.ContextTrackingMode = SECURITY_DYNAMIC_TRACKING;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: registry.c,v 1.15 2002/06/17 15:42:30 ekohl Exp $
|
/* $Id: registry.c,v 1.16 2002/08/20 20:37:10 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -113,7 +113,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
|
||||||
OUT PHANDLE KeyHandle)
|
OUT PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
UNICODE_STRING KeyPath;
|
UNICODE_STRING KeyPath = UNICODE_STRING_INITIALIZER(L"\\Registry\\User\\.Default");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
Status = RtlFormatCurrentUserKeyPath(&KeyPath);
|
Status = RtlFormatCurrentUserKeyPath(&KeyPath);
|
||||||
|
@ -132,9 +132,6 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
|
||||||
return(STATUS_SUCCESS);
|
return(STATUS_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyPath,
|
|
||||||
L"\\Registry\\User\\.Default");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyPath,
|
&KeyPath,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
#include <ddk/ntddk.h>
|
#include <ddk/ntddk.h>
|
||||||
|
|
||||||
#define STUB(x) void x(void) { \
|
#define STUB(x) void x(void) { \
|
||||||
UNICODE_STRING UnicodeString; \
|
UNICODE_STRING UnicodeString = \
|
||||||
RtlInitUnicodeString(&UnicodeString,\
|
UNICODE_STRING_INITIALIZER( \
|
||||||
L"NTDLL: Stub for "#x"\n"); \
|
L"NTDLL: Stub for "#x"\n" \
|
||||||
|
); \
|
||||||
NtDisplayString(&UnicodeString); }
|
NtDisplayString(&UnicodeString); }
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: lsa.c,v 1.2 2001/06/25 12:32:56 ekohl Exp $
|
/* $Id: lsa.c,v 1.3 2002/08/20 20:37:11 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS system libraries
|
* PROJECT: ReactOS system libraries
|
||||||
|
@ -256,13 +256,12 @@ LsaRegisterLogonProcess(PLSA_STRING LsaLogonProcessName,
|
||||||
PHANDLE Handle,
|
PHANDLE Handle,
|
||||||
PLSA_OPERATIONAL_MODE OperationalMode)
|
PLSA_OPERATIONAL_MODE OperationalMode)
|
||||||
{
|
{
|
||||||
UNICODE_STRING Portname;
|
UNICODE_STRING Portname = UNICODE_STRING_INITIALIZER(L"\\SeLsaCommandPort");
|
||||||
ULONG ConnectInfoLength;
|
ULONG ConnectInfoLength;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
LSASS_REQUEST Request;
|
LSASS_REQUEST Request;
|
||||||
LSASS_REPLY Reply;
|
LSASS_REPLY Reply;
|
||||||
|
|
||||||
RtlInitUnicodeString(&Portname, L"\\SeLsaCommandPort");
|
|
||||||
ConnectInfoLength = 0;
|
ConnectInfoLength = 0;
|
||||||
Status = NtConnectPort(Handle,
|
Status = NtConnectPort(Handle,
|
||||||
&Portname,
|
&Portname,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: registry.c,v 1.73 2002/06/19 22:31:33 ekohl Exp $
|
/* $Id: registry.c,v 1.74 2002/08/20 20:37:11 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -566,7 +566,7 @@ CmiCreateCurrentControlSetLink(VOID)
|
||||||
|
|
||||||
DPRINT("Link target '%S'\n", TargetNameBuffer);
|
DPRINT("Link target '%S'\n", TargetNameBuffer);
|
||||||
|
|
||||||
RtlInitUnicodeString(&LinkName,
|
RtlInitUnicodeStringFromLiteral(&LinkName,
|
||||||
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
L"\\Registry\\Machine\\SYSTEM\\CurrentControlSet");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&LinkName,
|
&LinkName,
|
||||||
|
@ -586,7 +586,7 @@ CmiCreateCurrentControlSetLink(VOID)
|
||||||
return(Status);
|
return(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&LinkValue,
|
RtlInitUnicodeStringFromLiteral(&LinkValue,
|
||||||
L"SymbolicLinkValue");
|
L"SymbolicLinkValue");
|
||||||
Status=NtSetValueKey(KeyHandle,
|
Status=NtSetValueKey(KeyHandle,
|
||||||
&LinkValue,
|
&LinkValue,
|
||||||
|
|
|
@ -92,7 +92,7 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
|
||||||
OUT PHANDLE KeyHandle)
|
OUT PHANDLE KeyHandle)
|
||||||
{
|
{
|
||||||
OBJECT_ATTRIBUTES ObjectAttributes;
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
UNICODE_STRING KeyPath;
|
UNICODE_STRING KeyPath = UNICODE_STRING_INITIALIZER(L"\\Registry\\User\\.Default");
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
Status = RtlFormatCurrentUserKeyPath(&KeyPath);
|
Status = RtlFormatCurrentUserKeyPath(&KeyPath);
|
||||||
|
@ -111,9 +111,6 @@ RtlOpenCurrentUser(IN ACCESS_MASK DesiredAccess,
|
||||||
return(STATUS_SUCCESS);
|
return(STATUS_SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyPath,
|
|
||||||
L"\\Registry\\User\\.Default");
|
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&KeyPath,
|
&KeyPath,
|
||||||
OBJ_CASE_INSENSITIVE,
|
OBJ_CASE_INSENSITIVE,
|
||||||
|
|
|
@ -867,7 +867,7 @@ KdbLdrLoadAutoConfigDrivers(VOID)
|
||||||
* is created after their module entries
|
* is created after their module entries
|
||||||
*/
|
*/
|
||||||
|
|
||||||
RtlInitUnicodeString(&ModuleName, KERNEL_MODULE_NAME);
|
RtlInitUnicodeStringFromLiteral(&ModuleName, KERNEL_MODULE_NAME);
|
||||||
ModuleObject = LdrGetModuleObject(&ModuleName);
|
ModuleObject = LdrGetModuleObject(&ModuleName);
|
||||||
if (ModuleObject != NULL)
|
if (ModuleObject != NULL)
|
||||||
{
|
{
|
||||||
|
@ -875,7 +875,7 @@ KdbLdrLoadAutoConfigDrivers(VOID)
|
||||||
&ModuleObject->TextSection->SymbolInfo);
|
&ModuleObject->TextSection->SymbolInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&ModuleName, HAL_MODULE_NAME);
|
RtlInitUnicodeStringFromLiteral(&ModuleName, HAL_MODULE_NAME);
|
||||||
ModuleObject = LdrGetModuleObject(&ModuleName);
|
ModuleObject = LdrGetModuleObject(&ModuleName);
|
||||||
if (ModuleObject != NULL)
|
if (ModuleObject != NULL)
|
||||||
{
|
{
|
||||||
|
|
|
@ -284,7 +284,7 @@ ExpWin32kInit(VOID)
|
||||||
ExWindowStationObjectType->OkayToClose = NULL;
|
ExWindowStationObjectType->OkayToClose = NULL;
|
||||||
ExWindowStationObjectType->Create = ExpWinStaObjectCreate;
|
ExWindowStationObjectType->Create = ExpWinStaObjectCreate;
|
||||||
ExWindowStationObjectType->DuplicationNotify = NULL;
|
ExWindowStationObjectType->DuplicationNotify = NULL;
|
||||||
RtlInitUnicodeString(&ExWindowStationObjectType->TypeName, L"WindowStation");
|
RtlInitUnicodeStringFromLiteral(&ExWindowStationObjectType->TypeName, L"WindowStation");
|
||||||
|
|
||||||
/* Create desktop object type */
|
/* Create desktop object type */
|
||||||
ExDesktopObjectType = ExAllocatePool(NonPagedPool, sizeof(OBJECT_TYPE));
|
ExDesktopObjectType = ExAllocatePool(NonPagedPool, sizeof(OBJECT_TYPE));
|
||||||
|
@ -312,7 +312,7 @@ ExpWin32kInit(VOID)
|
||||||
ExDesktopObjectType->OkayToClose = NULL;
|
ExDesktopObjectType->OkayToClose = NULL;
|
||||||
ExDesktopObjectType->Create = ExpDesktopObjectCreate;
|
ExDesktopObjectType->Create = ExpDesktopObjectCreate;
|
||||||
ExDesktopObjectType->DuplicationNotify = NULL;
|
ExDesktopObjectType->DuplicationNotify = NULL;
|
||||||
RtlInitUnicodeString(&ExDesktopObjectType->TypeName, L"Desktop");
|
RtlInitUnicodeStringFromLiteral(&ExDesktopObjectType->TypeName, L"Desktop");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* EOF */
|
/* EOF */
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: arcname.c,v 1.5 2002/06/27 17:45:45 ekohl Exp $
|
/* $Id: arcname.c,v 1.6 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -274,7 +274,7 @@ IoCreateSystemRootLink(PCHAR ParameterLine)
|
||||||
DPRINT("DeviceName: %wZ\n", &DeviceName);
|
DPRINT("DeviceName: %wZ\n", &DeviceName);
|
||||||
|
|
||||||
/* create the '\SystemRoot' link */
|
/* create the '\SystemRoot' link */
|
||||||
RtlInitUnicodeString(&LinkName,
|
RtlInitUnicodeStringFromLiteral(&LinkName,
|
||||||
L"\\SystemRoot");
|
L"\\SystemRoot");
|
||||||
|
|
||||||
Status = IoCreateSymbolicLink(&LinkName,
|
Status = IoCreateSymbolicLink(&LinkName,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: driver.c,v 1.9 2002/07/18 00:25:30 dwelch Exp $
|
/* $Id: driver.c,v 1.10 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -108,7 +108,7 @@ IopInitDriverImplementation(VOID)
|
||||||
IoDriverObjectType->OkayToClose = NULL;
|
IoDriverObjectType->OkayToClose = NULL;
|
||||||
IoDriverObjectType->Create = IopCreateDriver;
|
IoDriverObjectType->Create = IopCreateDriver;
|
||||||
IoDriverObjectType->DuplicationNotify = NULL;
|
IoDriverObjectType->DuplicationNotify = NULL;
|
||||||
RtlInitUnicodeString(&IoDriverObjectType->TypeName, L"Driver");
|
RtlInitUnicodeStringFromLiteral(&IoDriverObjectType->TypeName, L"Driver");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
|
@ -408,7 +408,7 @@ IoCreateDriverList(VOID)
|
||||||
return(Status);
|
return(Status);
|
||||||
|
|
||||||
/* Enumerate services and create the service list */
|
/* Enumerate services and create the service list */
|
||||||
RtlInitUnicodeString(&ServicesKeyName,
|
RtlInitUnicodeStringFromLiteral(&ServicesKeyName,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services");
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: iomgr.c,v 1.23 2002/08/14 20:58:34 dwelch Exp $
|
/* $Id: iomgr.c,v 1.24 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -146,7 +146,7 @@ VOID IoInit (VOID)
|
||||||
IoDeviceObjectType->Create = IopCreateDevice;
|
IoDeviceObjectType->Create = IopCreateDevice;
|
||||||
IoDeviceObjectType->DuplicationNotify = NULL;
|
IoDeviceObjectType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString (&IoDeviceObjectType->TypeName, L"Device");
|
RtlInitUnicodeStringFromLiteral(&IoDeviceObjectType->TypeName, L"Device");
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Register iomgr types: FileObjectType
|
* Register iomgr types: FileObjectType
|
||||||
|
@ -173,12 +173,12 @@ VOID IoInit (VOID)
|
||||||
IoFileObjectType->Create = IopCreateFile;
|
IoFileObjectType->Create = IopCreateFile;
|
||||||
IoFileObjectType->DuplicationNotify = NULL;
|
IoFileObjectType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString (&IoFileObjectType->TypeName, L"File");
|
RtlInitUnicodeStringFromLiteral(&IoFileObjectType->TypeName, L"File");
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create the '\Driver' object directory
|
* Create the '\Driver' object directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DirName, L"\\Driver");
|
RtlInitUnicodeStringFromLiteral(&DirName, L"\\Driver");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
0,
|
0,
|
||||||
|
@ -191,7 +191,7 @@ VOID IoInit (VOID)
|
||||||
/*
|
/*
|
||||||
* Create the '\FileSystem' object directory
|
* Create the '\FileSystem' object directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\FileSystem");
|
L"\\FileSystem");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
|
@ -205,7 +205,7 @@ VOID IoInit (VOID)
|
||||||
/*
|
/*
|
||||||
* Create the '\Device' directory
|
* Create the '\Device' directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\Device");
|
L"\\Device");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
|
@ -219,7 +219,7 @@ VOID IoInit (VOID)
|
||||||
/*
|
/*
|
||||||
* Create the '\??' directory
|
* Create the '\??' directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\??");
|
L"\\??");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
|
@ -233,7 +233,7 @@ VOID IoInit (VOID)
|
||||||
/*
|
/*
|
||||||
* Create the '\ArcName' directory
|
* Create the '\ArcName' directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\ArcName");
|
L"\\ArcName");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DirName,
|
&DirName,
|
||||||
|
@ -256,9 +256,9 @@ VOID IoInit (VOID)
|
||||||
/*
|
/*
|
||||||
* Create link from '\DosDevices' to '\??' directory
|
* Create link from '\DosDevices' to '\??' directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&LinkName,
|
RtlInitUnicodeStringFromLiteral(&LinkName,
|
||||||
L"\\DosDevices");
|
L"\\DosDevices");
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\??");
|
L"\\??");
|
||||||
IoCreateSymbolicLink(&LinkName,
|
IoCreateSymbolicLink(&LinkName,
|
||||||
&DirName);
|
&DirName);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: pnproot.c,v 1.7 2002/05/05 14:57:43 chorns Exp $
|
/* $Id: pnproot.c,v 1.8 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -467,7 +467,7 @@ PnpRootFdoEnumerateDevices(
|
||||||
return STATUS_INSUFFICIENT_RESOURCES;
|
return STATUS_INSUFFICIENT_RESOURCES;
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(
|
RtlInitUnicodeStringFromLiteral(
|
||||||
&KeyName,
|
&KeyName,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Enum\\" \
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Enum\\" \
|
||||||
ENUM_NAME_ROOT);
|
ENUM_NAME_ROOT);
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: resource.c,v 1.8 2001/09/27 02:14:34 dwelch Exp $
|
/* $Id: resource.c,v 1.9 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
* FILE: ntoskrnl/io/resource.c
|
* FILE: ntoskrnl/io/resource.c
|
||||||
|
@ -180,7 +180,7 @@ IoReportHalResourceUsage(PUNICODE_STRING HalDescription,
|
||||||
HANDLE DescriptionKey;
|
HANDLE DescriptionKey;
|
||||||
|
|
||||||
/* Open/Create 'RESOURCEMAP' key. */
|
/* Open/Create 'RESOURCEMAP' key. */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeStringFromLiteral(&Name,
|
||||||
L"\\Registry\\Machine\\HARDWARE\\RESOURCEMAP");
|
L"\\Registry\\Machine\\HARDWARE\\RESOURCEMAP");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&Name,
|
&Name,
|
||||||
|
@ -198,7 +198,7 @@ IoReportHalResourceUsage(PUNICODE_STRING HalDescription,
|
||||||
return(Status);
|
return(Status);
|
||||||
|
|
||||||
/* Open/Create 'Hardware Abstraction Layer' key */
|
/* Open/Create 'Hardware Abstraction Layer' key */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeStringFromLiteral(&Name,
|
||||||
L"Hardware Abstraction Layer");
|
L"Hardware Abstraction Layer");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&Name,
|
&Name,
|
||||||
|
@ -234,7 +234,7 @@ IoReportHalResourceUsage(PUNICODE_STRING HalDescription,
|
||||||
return(Status);
|
return(Status);
|
||||||
|
|
||||||
/* Add '.Raw' value. */
|
/* Add '.Raw' value. */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeStringFromLiteral(&Name,
|
||||||
L".Raw");
|
L".Raw");
|
||||||
Status = NtSetValueKey(DescriptionKey,
|
Status = NtSetValueKey(DescriptionKey,
|
||||||
&Name,
|
&Name,
|
||||||
|
@ -249,7 +249,7 @@ IoReportHalResourceUsage(PUNICODE_STRING HalDescription,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Add '.Translated' value. */
|
/* Add '.Translated' value. */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeStringFromLiteral(&Name,
|
||||||
L".Translated");
|
L".Translated");
|
||||||
Status = NtSetValueKey(DescriptionKey,
|
Status = NtSetValueKey(DescriptionKey,
|
||||||
&Name,
|
&Name,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: symlink.c,v 1.28 2002/06/27 17:46:53 ekohl Exp $
|
/* $Id: symlink.c,v 1.29 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -166,7 +166,7 @@ VOID IoInitSymbolicLinkImplementation (VOID)
|
||||||
IoSymbolicLinkType->Create = IopCreateSymbolicLink;
|
IoSymbolicLinkType->Create = IopCreateSymbolicLink;
|
||||||
IoSymbolicLinkType->DuplicationNotify = NULL;
|
IoSymbolicLinkType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&IoSymbolicLinkType->TypeName,
|
RtlInitUnicodeStringFromLiteral(&IoSymbolicLinkType->TypeName,
|
||||||
L"SymbolicLink");
|
L"SymbolicLink");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: dlog.c,v 1.4 2001/08/30 20:38:19 dwelch Exp $
|
/* $Id: dlog.c,v 1.5 2002/08/20 20:37:12 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -119,7 +119,7 @@ DebugLogInit2(VOID)
|
||||||
UNICODE_STRING FileName;
|
UNICODE_STRING FileName;
|
||||||
IO_STATUS_BLOCK Iosb;
|
IO_STATUS_BLOCK Iosb;
|
||||||
|
|
||||||
RtlInitUnicodeString(&FileName, L"\\SystemRoot\\debug.log");
|
RtlInitUnicodeStringFromLiteral(&FileName, L"\\SystemRoot\\debug.log");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&FileName,
|
&FileName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -76,7 +76,7 @@ NTSTATUS LdrLoadInitialProcess (VOID)
|
||||||
* Get the absolute path to smss.exe using the
|
* Get the absolute path to smss.exe using the
|
||||||
* SystemRoot link.
|
* SystemRoot link.
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&ProcessName,
|
RtlInitUnicodeStringFromLiteral(&ProcessName,
|
||||||
L"\\SystemRoot\\system32\\smss.exe");
|
L"\\SystemRoot\\system32\\smss.exe");
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -73,7 +73,7 @@ NTSTATUS LdrpMapSystemDll(HANDLE ProcessHandle,
|
||||||
OBJECT_ATTRIBUTES FileObjectAttributes;
|
OBJECT_ATTRIBUTES FileObjectAttributes;
|
||||||
HANDLE FileHandle;
|
HANDLE FileHandle;
|
||||||
HANDLE NTDllSectionHandle;
|
HANDLE NTDllSectionHandle;
|
||||||
UNICODE_STRING DllPathname;
|
UNICODE_STRING DllPathname = UNICODE_STRING_INITIALIZER(L"\\SystemRoot\\system32\\ntdll.dll");
|
||||||
PIMAGE_DOS_HEADER DosHeader;
|
PIMAGE_DOS_HEADER DosHeader;
|
||||||
PIMAGE_NT_HEADERS NTHeaders;
|
PIMAGE_NT_HEADERS NTHeaders;
|
||||||
PEPROCESS Process;
|
PEPROCESS Process;
|
||||||
|
@ -85,8 +85,6 @@ NTSTATUS LdrpMapSystemDll(HANDLE ProcessHandle,
|
||||||
* Locate and open NTDLL to determine ImageBase
|
* Locate and open NTDLL to determine ImageBase
|
||||||
* and LdrStartup
|
* and LdrStartup
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&DllPathname,
|
|
||||||
L"\\SystemRoot\\system32\\ntdll.dll");
|
|
||||||
InitializeObjectAttributes(&FileObjectAttributes,
|
InitializeObjectAttributes(&FileObjectAttributes,
|
||||||
&DllPathname,
|
&DllPathname,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: port.c,v 1.8 2001/12/05 01:40:24 dwelch Exp $
|
/* $Id: port.c,v 1.9 2002/08/20 20:37:13 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -44,7 +44,7 @@ NTSTATUS NiInitPort (VOID)
|
||||||
{
|
{
|
||||||
ExPortType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
ExPortType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
||||||
|
|
||||||
RtlInitUnicodeString(&ExPortType->TypeName,L"Port");
|
RtlInitUnicodeStringFromLiteral(&ExPortType->TypeName,L"Port");
|
||||||
|
|
||||||
ExPortType->Tag = TAG('L', 'P', 'R', 'T');
|
ExPortType->Tag = TAG('L', 'P', 'R', 'T');
|
||||||
ExPortType->MaxObjects = ULONG_MAX;
|
ExPortType->MaxObjects = ULONG_MAX;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: section.c,v 1.91 2002/08/17 15:12:49 hbirr Exp $
|
/* $Id: section.c,v 1.92 2002/08/20 20:37:13 hyperion Exp $
|
||||||
*
|
*
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
* FILE: ntoskrnl/mm/section.c
|
* FILE: ntoskrnl/mm/section.c
|
||||||
|
@ -1842,14 +1842,13 @@ MmCreatePhysicalMemorySection(VOID)
|
||||||
PSECTION_OBJECT PhysSection;
|
PSECTION_OBJECT PhysSection;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
OBJECT_ATTRIBUTES Obj;
|
OBJECT_ATTRIBUTES Obj;
|
||||||
UNICODE_STRING Name;
|
UNICODE_STRING Name = UNICODE_STRING_INITIALIZER(L"\\Device\\PhysicalMemory");
|
||||||
LARGE_INTEGER SectionSize;
|
LARGE_INTEGER SectionSize;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create the section mapping physical memory
|
* Create the section mapping physical memory
|
||||||
*/
|
*/
|
||||||
SectionSize.QuadPart = 0xFFFFFFFF;
|
SectionSize.QuadPart = 0xFFFFFFFF;
|
||||||
RtlInitUnicodeString(&Name, L"\\Device\\PhysicalMemory");
|
|
||||||
InitializeObjectAttributes(&Obj,
|
InitializeObjectAttributes(&Obj,
|
||||||
&Name,
|
&Name,
|
||||||
0,
|
0,
|
||||||
|
@ -1889,7 +1888,7 @@ MmInitSectionImplementation(VOID)
|
||||||
{
|
{
|
||||||
MmSectionObjectType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
MmSectionObjectType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
||||||
|
|
||||||
RtlInitUnicodeString(&MmSectionObjectType->TypeName, L"Section");
|
RtlInitUnicodeStringFromLiteral(&MmSectionObjectType->TypeName, L"Section");
|
||||||
|
|
||||||
MmSectionObjectType->Tag = TAG('S', 'E', 'C', 'T');
|
MmSectionObjectType->Tag = TAG('S', 'E', 'C', 'T');
|
||||||
MmSectionObjectType->TotalObjects = 0;
|
MmSectionObjectType->TotalObjects = 0;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: namespc.c,v 1.31 2002/06/20 21:31:39 ekohl Exp $
|
/* $Id: namespc.c,v 1.32 2002/08/20 20:37:14 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -354,7 +354,7 @@ ObInit(VOID)
|
||||||
ObDirectoryType->Create = ObpCreateDirectory;
|
ObDirectoryType->Create = ObpCreateDirectory;
|
||||||
ObDirectoryType->DuplicationNotify = NULL;
|
ObDirectoryType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&ObDirectoryType->TypeName,
|
RtlInitUnicodeStringFromLiteral(&ObDirectoryType->TypeName,
|
||||||
L"Directory");
|
L"Directory");
|
||||||
|
|
||||||
/* create 'type' object type*/
|
/* create 'type' object type*/
|
||||||
|
@ -379,7 +379,7 @@ ObInit(VOID)
|
||||||
ObTypeObjectType->Create = NULL;
|
ObTypeObjectType->Create = NULL;
|
||||||
ObTypeObjectType->DuplicationNotify = NULL;
|
ObTypeObjectType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&ObTypeObjectType->TypeName,
|
RtlInitUnicodeStringFromLiteral(&ObTypeObjectType->TypeName,
|
||||||
L"ObjectType");
|
L"ObjectType");
|
||||||
|
|
||||||
/* create root directory */
|
/* create root directory */
|
||||||
|
@ -390,7 +390,7 @@ ObInit(VOID)
|
||||||
(PVOID*)&NameSpaceRoot);
|
(PVOID*)&NameSpaceRoot);
|
||||||
|
|
||||||
/* create '\ObjectTypes' directory */
|
/* create '\ObjectTypes' directory */
|
||||||
RtlInitUnicodeString(&Name,
|
RtlInitUnicodeStringFromLiteral(&Name,
|
||||||
L"\\ObjectTypes");
|
L"\\ObjectTypes");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&Name,
|
&Name,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: locale.c,v 1.1 2001/07/12 17:21:06 ekohl Exp $
|
/* $Id: locale.c,v 1.2 2002/08/20 20:37:14 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -57,9 +57,9 @@ PiInitDefaultLocale(VOID)
|
||||||
ValueInfo = (PKEY_VALUE_PARTIAL_INFORMATION)ValueBuffer;
|
ValueInfo = (PKEY_VALUE_PARTIAL_INFORMATION)ValueBuffer;
|
||||||
|
|
||||||
/* read system locale */
|
/* read system locale */
|
||||||
RtlInitUnicodeString(&KeyName,
|
RtlInitUnicodeStringFromLiteral(&KeyName,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\Nls\\Language");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\Nls\\Language");
|
||||||
RtlInitUnicodeString(&ValueName,
|
RtlInitUnicodeStringFromLiteral(&ValueName,
|
||||||
L"Default");
|
L"Default");
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
@ -97,9 +97,9 @@ PiInitDefaultLocale(VOID)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* read default thread locale */
|
/* read default thread locale */
|
||||||
RtlInitUnicodeString(&KeyName,
|
RtlInitUnicodeStringFromLiteral(&KeyName,
|
||||||
L"\\Registry\\User\\.Default\\Control Panel\\International");
|
L"\\Registry\\User\\.Default\\Control Panel\\International");
|
||||||
RtlInitUnicodeString(&ValueName,
|
RtlInitUnicodeStringFromLiteral(&ValueName,
|
||||||
L"Locale");
|
L"Locale");
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
@ -199,17 +199,17 @@ NtSetDefaultLocale(IN BOOLEAN ThreadOrSystem,
|
||||||
&UserKey);
|
&UserKey);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
return(Status);
|
return(Status);
|
||||||
RtlInitUnicodeString(&KeyName,
|
RtlInitUnicodeStringFromLiteral(&KeyName,
|
||||||
L"Control Panel\\International");
|
L"Control Panel\\International");
|
||||||
RtlInitUnicodeString(&ValueName,
|
RtlInitUnicodeStringFromLiteral(&ValueName,
|
||||||
L"Locale");
|
L"Locale");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
/* system locale */
|
/* system locale */
|
||||||
RtlInitUnicodeString(&KeyName,
|
RtlInitUnicodeStringFromLiteral(&KeyName,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\Nls\\Language");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\Nls\\Language");
|
||||||
RtlInitUnicodeString(&ValueName,
|
RtlInitUnicodeStringFromLiteral(&ValueName,
|
||||||
L"Default");
|
L"Default");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: process.c,v 1.88 2002/07/18 00:25:31 dwelch Exp $
|
/* $Id: process.c,v 1.89 2002/08/20 20:37:14 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -224,7 +224,7 @@ PsInitProcessManagment(VOID)
|
||||||
PsProcessType->Create = NULL;
|
PsProcessType->Create = NULL;
|
||||||
PsProcessType->DuplicationNotify = NULL;
|
PsProcessType->DuplicationNotify = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&PsProcessType->TypeName, L"Process");
|
RtlInitUnicodeStringFromLiteral(&PsProcessType->TypeName, L"Process");
|
||||||
|
|
||||||
InitializeListHead(&PsProcessListHead);
|
InitializeListHead(&PsProcessListHead);
|
||||||
KeInitializeSpinLock(&PsProcessListLock);
|
KeInitializeSpinLock(&PsProcessListLock);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: thread.c,v 1.103 2002/08/17 01:42:03 dwelch Exp $
|
/* $Id: thread.c,v 1.104 2002/08/20 20:37:14 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -414,7 +414,7 @@ PsInitThreadManagment(VOID)
|
||||||
|
|
||||||
PsThreadType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
PsThreadType = ExAllocatePool(NonPagedPool,sizeof(OBJECT_TYPE));
|
||||||
|
|
||||||
RtlInitUnicodeString(&PsThreadType->TypeName, L"Thread");
|
RtlInitUnicodeStringFromLiteral(&PsThreadType->TypeName, L"Thread");
|
||||||
|
|
||||||
PsThreadType->Tag = TAG('T', 'H', 'R', 'T');
|
PsThreadType->Tag = TAG('T', 'H', 'R', 'T');
|
||||||
PsThreadType->TotalObjects = 0;
|
PsThreadType->TotalObjects = 0;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: nls.c,v 1.6 2001/11/02 09:10:49 ekohl Exp $
|
/* $Id: nls.c,v 1.7 2002/08/20 20:37:16 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -166,7 +166,7 @@ RtlpInitNlsSections(ULONG Mod1Start,
|
||||||
DPRINT("Upcase section end: 0x%08lX\n", Mod3End);
|
DPRINT("Upcase section end: 0x%08lX\n", Mod3End);
|
||||||
|
|
||||||
/* Create the '\NLS' directory */
|
/* Create the '\NLS' directory */
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\NLS");
|
L"\\NLS");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
@ -180,7 +180,7 @@ RtlpInitNlsSections(ULONG Mod1Start,
|
||||||
return(Status);
|
return(Status);
|
||||||
|
|
||||||
/* Create the 'NlsSectionUnicode' section */
|
/* Create the 'NlsSectionUnicode' section */
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"NlsSectionUnicode");
|
L"NlsSectionUnicode");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
*/
|
||||||
/* $Id: logport.c,v 1.1 2002/06/25 21:10:14 ekohl Exp $
|
/* $Id: logport.c,v 1.2 2002/08/20 20:37:16 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -60,7 +60,7 @@ InitLogPort(VOID)
|
||||||
ConnectPortHandle = NULL;
|
ConnectPortHandle = NULL;
|
||||||
MessagePortHandle = NULL;
|
MessagePortHandle = NULL;
|
||||||
|
|
||||||
RtlInitUnicodeString(&PortName,
|
RtlInitUnicodeStringFromLiteral(&PortName,
|
||||||
L"\\ErrorLogPort");
|
L"\\ErrorLogPort");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&PortName,
|
&PortName,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: conio.c,v 1.30 2002/05/07 22:44:23 hbirr Exp $
|
/* $Id: conio.c,v 1.31 2002/08/20 20:37:16 hyperion Exp $
|
||||||
*
|
*
|
||||||
* reactos/subsys/csrss/api/conio.c
|
* reactos/subsys/csrss/api/conio.c
|
||||||
*
|
*
|
||||||
|
@ -786,7 +786,7 @@ VOID STDCALL CsrInitConsoleSupport(VOID)
|
||||||
|
|
||||||
DPRINT("CSR: CsrInitConsoleSupport()\n");
|
DPRINT("CSR: CsrInitConsoleSupport()\n");
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\??\\BlueScreen");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\??\\BlueScreen");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
0,
|
0,
|
||||||
|
@ -803,7 +803,7 @@ VOID STDCALL CsrInitConsoleSupport(VOID)
|
||||||
DbgPrint("CSR: Failed to open console. Expect problems.\n");
|
DbgPrint("CSR: Failed to open console. Expect problems.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\??\\Keyboard");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\??\\Keyboard");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: csrss.c,v 1.10 2002/02/08 02:57:10 chorns Exp $
|
/* $Id: csrss.c,v 1.11 2002/08/20 20:37:17 hyperion Exp $
|
||||||
*
|
*
|
||||||
* csrss.c - Client/Server Runtime subsystem
|
* csrss.c - Client/Server Runtime subsystem
|
||||||
*
|
*
|
||||||
|
@ -88,7 +88,7 @@ VOID NtProcessStartup(PPEB Peb)
|
||||||
argv[argc-1] = &(ArgBuffer[afterlastspace]);
|
argv[argc-1] = &(ArgBuffer[afterlastspace]);
|
||||||
}
|
}
|
||||||
|
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\CsrssInitDone");
|
L"\\CsrssInitDone");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: init.c,v 1.13 2002/06/14 14:23:14 ekohl Exp $
|
/* $Id: init.c,v 1.14 2002/08/20 20:37:17 hyperion Exp $
|
||||||
*
|
*
|
||||||
* reactos/subsys/csrss/init.c
|
* reactos/subsys/csrss/init.c
|
||||||
*
|
*
|
||||||
|
@ -84,7 +84,7 @@ CsrInitVideo(VOID)
|
||||||
HANDLE VideoHandle;
|
HANDLE VideoHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\??\\DISPLAY1");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\??\\DISPLAY1");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
0,
|
0,
|
||||||
|
@ -140,7 +140,7 @@ CsrServerInitialization (
|
||||||
CsrInitVideo();
|
CsrInitVideo();
|
||||||
|
|
||||||
/* NEW NAMED PORT: \ApiPort */
|
/* NEW NAMED PORT: \ApiPort */
|
||||||
RtlInitUnicodeString(&PortName, L"\\Windows\\ApiPort");
|
RtlInitUnicodeStringFromLiteral(&PortName, L"\\Windows\\ApiPort");
|
||||||
InitializeObjectAttributes(&ObAttributes,
|
InitializeObjectAttributes(&ObAttributes,
|
||||||
&PortName,
|
&PortName,
|
||||||
0,
|
0,
|
||||||
|
@ -186,7 +186,7 @@ CsrServerInitialization (
|
||||||
NtClose(ApiPortHandle);
|
NtClose(ApiPortHandle);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
RtlInitUnicodeString( &RefreshEventName, L"\\TextConsoleRefreshEvent" );
|
RtlInitUnicodeStringFromLiteral( &RefreshEventName, L"\\TextConsoleRefreshEvent" );
|
||||||
InitializeObjectAttributes( &RefreshEventAttr, &RefreshEventName, 0, NULL, NULL );
|
InitializeObjectAttributes( &RefreshEventAttr, &RefreshEventName, 0, NULL, NULL );
|
||||||
Status = NtCreateEvent( &RefreshEventHandle, STANDARD_RIGHTS_ALL, &RefreshEventAttr, FALSE, FALSE );
|
Status = NtCreateEvent( &RefreshEventHandle, STANDARD_RIGHTS_ALL, &RefreshEventAttr, FALSE, FALSE );
|
||||||
if( !NT_SUCCESS( Status ) )
|
if( !NT_SUCCESS( Status ) )
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: video.c,v 1.3 2001/08/14 12:57:16 ea Exp $
|
/* $Id: video.c,v 1.4 2002/08/20 20:37:17 hyperion Exp $
|
||||||
*
|
*
|
||||||
* ReactOS Project
|
* ReactOS Project
|
||||||
*/
|
*/
|
||||||
|
@ -21,7 +21,7 @@ InitializeVideoAddressSpace(VOID)
|
||||||
/*
|
/*
|
||||||
* Open the physical memory section
|
* Open the physical memory section
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&PhysMemName, L"\\Device\\PhysicalMemory");
|
RtlInitUnicodeStringFromLiteral(&PhysMemName, L"\\Device\\PhysicalMemory");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&PhysMemName,
|
&PhysMemName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: init.c,v 1.41 2002/08/17 15:31:03 hbirr Exp $
|
/* $Id: init.c,v 1.42 2002/08/20 20:37:17 hyperion Exp $
|
||||||
*
|
*
|
||||||
* init.c - Session Manager initialization
|
* init.c - Session Manager initialization
|
||||||
*
|
*
|
||||||
|
@ -517,7 +517,7 @@ SmSetEnvironmentVariables(VOID)
|
||||||
SharedUserData->NtSystemRoot);
|
SharedUserData->NtSystemRoot);
|
||||||
|
|
||||||
/* Cet SystemRoot = "C:\reactos" */
|
/* Cet SystemRoot = "C:\reactos" */
|
||||||
RtlInitUnicodeString(&EnvVariable,
|
RtlInitUnicodeStringFromLiteral(&EnvVariable,
|
||||||
L"SystemRoot");
|
L"SystemRoot");
|
||||||
RtlInitUnicodeString(&EnvValue,
|
RtlInitUnicodeString(&EnvValue,
|
||||||
ValueBuffer);
|
ValueBuffer);
|
||||||
|
@ -529,7 +529,7 @@ SmSetEnvironmentVariables(VOID)
|
||||||
ValueBuffer[2] = 0;
|
ValueBuffer[2] = 0;
|
||||||
|
|
||||||
/* Set SystemDrive = "C:" */
|
/* Set SystemDrive = "C:" */
|
||||||
RtlInitUnicodeString(&EnvVariable,
|
RtlInitUnicodeStringFromLiteral(&EnvVariable,
|
||||||
L"SystemDrive");
|
L"SystemDrive");
|
||||||
RtlInitUnicodeString(&EnvValue,
|
RtlInitUnicodeString(&EnvValue,
|
||||||
ValueBuffer);
|
ValueBuffer);
|
||||||
|
@ -560,7 +560,7 @@ SmLoadSubsystems(VOID)
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
/* Load kernel mode subsystem (aka win32k.sys) */
|
/* Load kernel mode subsystem (aka win32k.sys) */
|
||||||
RtlInitUnicodeString(&ImageInfo.ModuleName,
|
RtlInitUnicodeStringFromLiteral(&ImageInfo.ModuleName,
|
||||||
L"\\SystemRoot\\system32\\drivers\\win32k.sys");
|
L"\\SystemRoot\\system32\\drivers\\win32k.sys");
|
||||||
|
|
||||||
Status = NtSetSystemInformation(SystemLoadAndCallImage,
|
Status = NtSetSystemInformation(SystemLoadAndCallImage,
|
||||||
|
@ -678,7 +678,7 @@ InitSessionManager(HANDLE Children[])
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Run csrss.exe */
|
/* Run csrss.exe */
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\CsrssInitDone");
|
L"\\CsrssInitDone");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
@ -787,7 +787,7 @@ InitSessionManager(HANDLE Children[])
|
||||||
Children[CHILD_WINLOGON] = ProcessInfo.ProcessHandle;
|
Children[CHILD_WINLOGON] = ProcessInfo.ProcessHandle;
|
||||||
|
|
||||||
/* Create the \DbgSsApiPort object (LPC) */
|
/* Create the \DbgSsApiPort object (LPC) */
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\DbgSsApiPort");
|
L"\\DbgSsApiPort");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
@ -810,7 +810,7 @@ InitSessionManager(HANDLE Children[])
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Create the \DbgUiApiPort object (LPC) */
|
/* Create the \DbgUiApiPort object (LPC) */
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\DbgUiApiPort");
|
L"\\DbgUiApiPort");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: smapi.c,v 1.6 2002/05/24 07:49:41 ekohl Exp $
|
/* $Id: smapi.c,v 1.7 2002/08/20 20:37:17 hyperion Exp $
|
||||||
*
|
*
|
||||||
* Reactos Session Manager
|
* Reactos Session Manager
|
||||||
*
|
*
|
||||||
|
@ -78,7 +78,7 @@ SmCreateApiPort(VOID)
|
||||||
UNICODE_STRING UnicodeString;
|
UNICODE_STRING UnicodeString;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
L"\\SmApiPort");
|
L"\\SmApiPort");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&UnicodeString,
|
&UnicodeString,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: database.c,v 1.4 2002/07/20 13:34:10 ekohl Exp $
|
/* $Id: database.c,v 1.5 2002/08/20 20:37:18 hyperion Exp $
|
||||||
*
|
*
|
||||||
* service control manager
|
* service control manager
|
||||||
*
|
*
|
||||||
|
@ -247,7 +247,7 @@ ScmCreateServiceDataBase(VOID)
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
return(Status);
|
return(Status);
|
||||||
|
|
||||||
RtlInitUnicodeString(&ServicesKeyName,
|
RtlInitUnicodeStringFromLiteral(&ServicesKeyName,
|
||||||
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services");
|
L"\\Registry\\Machine\\System\\CurrentControlSet\\Services");
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
@ -329,12 +329,12 @@ ScmCheckDriver(PSERVICE Service)
|
||||||
|
|
||||||
if (Service->Type == SERVICE_KERNEL_DRIVER)
|
if (Service->Type == SERVICE_KERNEL_DRIVER)
|
||||||
{
|
{
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\Driver");
|
L"\\Driver");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
RtlInitUnicodeString(&DirName,
|
RtlInitUnicodeStringFromLiteral(&DirName,
|
||||||
L"\\FileSystem");
|
L"\\FileSystem");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -96,14 +96,12 @@ NTSTATUS ConnectMouseClassDriver()
|
||||||
PDEVICE_OBJECT ClassDeviceObject = NULL;
|
PDEVICE_OBJECT ClassDeviceObject = NULL;
|
||||||
PFILE_OBJECT FileObject = NULL;
|
PFILE_OBJECT FileObject = NULL;
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
UNICODE_STRING ClassName;
|
UNICODE_STRING ClassName = UNICODE_STRING_INITIALIZER(L"\\Device\\MouseClass");
|
||||||
IO_STATUS_BLOCK ioStatus;
|
IO_STATUS_BLOCK ioStatus;
|
||||||
KEVENT event;
|
KEVENT event;
|
||||||
PIRP irp;
|
PIRP irp;
|
||||||
GDI_INFORMATION GDIInformation;
|
GDI_INFORMATION GDIInformation;
|
||||||
|
|
||||||
RtlInitUnicodeString(&ClassName, L"\\Device\\MouseClass");
|
|
||||||
|
|
||||||
status = IoGetDeviceObjectPointer(&ClassName, FILE_READ_ATTRIBUTES, &FileObject, &ClassDeviceObject);
|
status = IoGetDeviceObjectPointer(&ClassName, FILE_READ_ATTRIBUTES, &FileObject, &ClassDeviceObject);
|
||||||
|
|
||||||
if(status != STATUS_SUCCESS)
|
if(status != STATUS_SUCCESS)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: driver.c,v 1.19 2002/06/14 07:48:19 ekohl Exp $
|
/* $Id: driver.c,v 1.20 2002/08/20 20:37:18 hyperion Exp $
|
||||||
*
|
*
|
||||||
* GDI Driver support routines
|
* GDI Driver support routines
|
||||||
* (mostly swiped from Wine)
|
* (mostly swiped from Wine)
|
||||||
|
@ -169,7 +169,7 @@ HANDLE DRIVER_FindMPDriver(LPCWSTR Name)
|
||||||
HANDLE DisplayHandle;
|
HANDLE DisplayHandle;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&DeviceName, L"\\??\\DISPLAY1");
|
RtlInitUnicodeStringFromLiteral(&DeviceName, L"\\??\\DISPLAY1");
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
&DeviceName,
|
&DeviceName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: input.c,v 1.1 2002/01/14 01:11:58 dwelch Exp $
|
/* $Id: input.c,v 1.2 2002/08/20 20:37:19 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -40,7 +40,7 @@ KeyboardThreadMain(PVOID StartContext)
|
||||||
IO_STATUS_BLOCK Iosb;
|
IO_STATUS_BLOCK Iosb;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
RtlInitUnicodeString(&KeyboardDeviceName, L"\\??\\Keyboard");
|
RtlInitUnicodeStringFromLiteral(&KeyboardDeviceName, L"\\??\\Keyboard");
|
||||||
InitializeObjectAttributes(&KeyboardObjectAttributes,
|
InitializeObjectAttributes(&KeyboardObjectAttributes,
|
||||||
&KeyboardDeviceName,
|
&KeyboardDeviceName,
|
||||||
0,
|
0,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: winsta.c,v 1.6 2002/08/16 01:39:17 dwelch Exp $
|
/* $Id: winsta.c,v 1.7 2002/08/20 20:37:19 hyperion Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -63,7 +63,7 @@ InitWindowStationImpl(VOID)
|
||||||
/*
|
/*
|
||||||
* Create the '\Windows\WindowStations' directory
|
* Create the '\Windows\WindowStations' directory
|
||||||
*/
|
*/
|
||||||
RtlInitUnicodeString(&UnicodeString,
|
RtlInitUnicodeStringFromLiteral(&UnicodeString,
|
||||||
WINSTA_ROOT_NAME);
|
WINSTA_ROOT_NAME);
|
||||||
|
|
||||||
InitializeObjectAttributes(&ObjectAttributes,
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue