[CSRSRV]
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 20 Oct 2012 14:07:04 +0000 (14:07 +0000)
committerHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 20 Oct 2012 14:07:04 +0000 (14:07 +0000)
- Start renaming some APIs which should not be present there, but in basesrv instead.
Names come from http://j00ru.vexillium.org/csrss_list/api_list.html#Windows_2k3

svn path=/branches/ros-csrss/; revision=57583

subsystems/win32/csrsrv/api/process.c
subsystems/win32/csrsrv/api/user.c
subsystems/win32/csrsrv/include/api.h
subsystems/win32/csrsrv/init.c

index 7d82c06..46c4ce9 100644 (file)
@@ -23,7 +23,14 @@ extern NTSTATUS CallProcessCreated(PCSR_PROCESS, PCSR_PROCESS);
  *     CSRSS API
  *********************************************************************/
 
-CSR_API(CsrSrvCreateProcess)
+/***
+ *** Some APIs from here will go to basesrv.dll, some others to winsrv.dll.
+ *** Furthermore, this structure uses the old definition of APIs list.
+ *** The new one is in fact three arrays, one of APIs pointers, one other of
+ *** corresponding indexes, and the third one of names (not very efficient...).
+ ***/
+
+CSR_API(BaseSrvCreateProcess)
 {
      NTSTATUS Status;
      HANDLE ProcessHandle, ThreadHandle;
@@ -135,7 +142,7 @@ CSR_API(CsrSrvCreateProcess)
     return Status;
 }
 
-CSR_API(CsrSrvCreateThread)
+CSR_API(BaseSrvCreateThread)
 {
     PCSR_THREAD CurrentThread;
     HANDLE ThreadHandle;
@@ -191,7 +198,7 @@ CSR_API(CsrSrvCreateThread)
     return Status;
 }
 
-CSR_API(CsrTerminateProcess)
+CSR_API(BaseSrvExitProcess)
 {
     PCSR_THREAD CsrThread = CsrGetClientThread();
     ASSERT(CsrThread != NULL);
@@ -204,12 +211,7 @@ CSR_API(CsrTerminateProcess)
                              (NTSTATUS)ApiMessage->Data.TerminateProcessRequest.uExitCode);
 }
 
-CSR_API(CsrConnectProcess)
-{
-    return STATUS_SUCCESS;
-}
-
-CSR_API(CsrGetShutdownParameters)
+CSR_API(BaseSrvGetProcessShutdownParam)
 {
     PCSR_THREAD CsrThread = CsrGetClientThread();
     ASSERT(CsrThread);
@@ -220,7 +222,7 @@ CSR_API(CsrGetShutdownParameters)
     return STATUS_SUCCESS;
 }
 
-CSR_API(CsrSetShutdownParameters)
+CSR_API(BaseSrvSetProcessShutdownParam)
 {
     PCSR_THREAD CsrThread = CsrGetClientThread();
     ASSERT(CsrThread);
index 1ba4fb3..770e519 100644 (file)
@@ -23,7 +23,7 @@ static ULONG_PTR ServicesProcessId;
 
 /* FUNCTIONS *****************************************************************/
 
-CSR_API(CsrRegisterServicesProcess)
+CSR_API(SrvRegisterServicesProcess)
 {
   if (ServicesProcessIdValid == TRUE)
     {
index 1466370..a621d9c 100644 (file)
@@ -71,11 +71,11 @@ NTSTATUS NTAPI CsrServerInitialization(ULONG ArgumentCount, PCHAR Arguments[]);
 
 /* api/process.c */
 CSR_API(CsrConnectProcess);
-CSR_API(CsrSrvCreateProcess);
-CSR_API(CsrTerminateProcess);
-CSR_API(CsrSrvCreateThread);
-CSR_API(CsrGetShutdownParameters);
-CSR_API(CsrSetShutdownParameters);
+CSR_API(BaseSrvCreateProcess);
+CSR_API(BaseSrvExitProcess);
+CSR_API(BaseSrvCreateThread);
+CSR_API(BaseSrvGetProcessShutdownParam);
+CSR_API(BaseSrvSetProcessShutdownParam);
 
 VOID
 NTAPI
@@ -263,6 +263,6 @@ CsrLoadServerDll(IN PCHAR DllString,
                  IN ULONG ServerId);
 
 /* api/user.c */
-CSR_API(CsrRegisterServicesProcess);
+CSR_API(SrvRegisterServicesProcess);
 
 /* EOF */
index af7f76a..ea5db55 100644 (file)
@@ -94,13 +94,12 @@ CallProcessCreated(IN PCSR_PROCESS SourceProcessData,
  ***/
 CSRSS_API_DEFINITION NativeDefinitions[] =
 {
-    CSRSS_DEFINE_API(CREATE_PROCESS,               CsrSrvCreateProcess),
-    CSRSS_DEFINE_API(CREATE_THREAD,                CsrSrvCreateThread),
-    CSRSS_DEFINE_API(TERMINATE_PROCESS,            CsrTerminateProcess),
-    CSRSS_DEFINE_API(CONNECT_PROCESS,              CsrConnectProcess),
-    CSRSS_DEFINE_API(REGISTER_SERVICES_PROCESS,    CsrRegisterServicesProcess),
-    CSRSS_DEFINE_API(GET_SHUTDOWN_PARAMETERS,      CsrGetShutdownParameters),
-    CSRSS_DEFINE_API(SET_SHUTDOWN_PARAMETERS,      CsrSetShutdownParameters),
+    CSRSS_DEFINE_API(CREATE_PROCESS,               BaseSrvCreateProcess),
+    CSRSS_DEFINE_API(CREATE_THREAD,                BaseSrvCreateThread),
+    CSRSS_DEFINE_API(TERMINATE_PROCESS,            BaseSrvExitProcess),
+    CSRSS_DEFINE_API(REGISTER_SERVICES_PROCESS,    SrvRegisterServicesProcess),
+    CSRSS_DEFINE_API(GET_SHUTDOWN_PARAMETERS,      BaseSrvGetProcessShutdownParam),
+    CSRSS_DEFINE_API(SET_SHUTDOWN_PARAMETERS,      BaseSrvSetProcessShutdownParam),
     { 0, 0, NULL }
 };