branch update for HEAD-2003021201
[reactos.git] / lib / ntdll / rtl / ppb.c
index 50feb7b..99243a9 100644 (file)
@@ -97,10 +97,10 @@ RtlCreateProcessParameters(PRTL_USER_PROCESS_PARAMETERS *ProcessParameters,
        if (Environment == NULL)
          Environment  = NtCurrentPeb()->ProcessParameters->Environment;
        if (CurrentDirectory == NULL)
-         CurrentDirectory = &NtCurrentPeb()->ProcessParameters->CurrentDirectoryName;\r
-       CurrentDirectoryHandle = NtCurrentPeb()->ProcessParameters->CurrentDirectoryHandle;\r
-       ConsoleHandle = NtCurrentPeb()->ProcessParameters->hConsole;\r
-       ConsoleFlags = NtCurrentPeb()->ProcessParameters->ProcessGroup;\r
+         CurrentDirectory = &NtCurrentPeb()->ProcessParameters->CurrentDirectoryName;
+       CurrentDirectoryHandle = NtCurrentPeb()->ProcessParameters->CurrentDirectoryHandle;
+       ConsoleHandle = NtCurrentPeb()->ProcessParameters->hConsole;
+       ConsoleFlags = NtCurrentPeb()->ProcessParameters->ProcessGroup;
      }
    else
      {
@@ -156,33 +156,33 @@ RtlCreateProcessParameters(PRTL_USER_PROCESS_PARAMETERS *ProcessParameters,
 
    DPRINT ("Process parameters allocated\n");
 
-   Param->AllocationSize = RegionSize;\r
-   Param->Size = Length;\r
+   Param->AllocationSize = RegionSize;
+   Param->Size = Length;
    Param->Flags = PPF_NORMALIZED;
    Param->Environment = Environment;
-   Param->CurrentDirectoryHandle = CurrentDirectoryHandle;\r
-   Param->hConsole = ConsoleHandle;\r
-   Param->ProcessGroup = ConsoleFlags;\r
+   Param->CurrentDirectoryHandle = CurrentDirectoryHandle;
+   Param->hConsole = ConsoleHandle;
+   Param->ProcessGroup = ConsoleFlags;
 
    Dest = (PWCHAR)(((PBYTE)Param) + sizeof(RTL_USER_PROCESS_PARAMETERS));
 
    /* copy current directory */
    RtlpCopyParameterString(&Dest,
-                          &Param->CurrentDirectoryName,\r
+                          &Param->CurrentDirectoryName,
                           CurrentDirectory,
                           MAX_PATH * sizeof(WCHAR));
 
    /* make sure the current directory has a trailing backslash */
-   if (Param->CurrentDirectoryName.Length > 0)\r
+   if (Param->CurrentDirectoryName.Length > 0)
      {
        ULONG Length;
 
-       Length = Param->CurrentDirectoryName.Length / sizeof(WCHAR);\r
-       if (Param->CurrentDirectoryName.Buffer[Length-1] != L'\\')\r
+       Length = Param->CurrentDirectoryName.Length / sizeof(WCHAR);
+       if (Param->CurrentDirectoryName.Buffer[Length-1] != L'\\')
          {
-            Param->CurrentDirectoryName.Buffer[Length] = L'\\';\r
-            Param->CurrentDirectoryName.Buffer[Length + 1] = 0;\r
-            Param->CurrentDirectoryName.Length += sizeof(WCHAR);\r
+            Param->CurrentDirectoryName.Buffer[Length] = L'\\';
+            Param->CurrentDirectoryName.Buffer[Length + 1] = 0;
+            Param->CurrentDirectoryName.Length += sizeof(WCHAR);
          }
      }
 
@@ -235,12 +235,12 @@ RtlCreateProcessParameters(PRTL_USER_PROCESS_PARAMETERS *ProcessParameters,
    return STATUS_SUCCESS;
 }
 
-VOID STDCALL
+NTSTATUS STDCALL
 RtlDestroyProcessParameters(PRTL_USER_PROCESS_PARAMETERS ProcessParameters)
 {
    ULONG RegionSize = 0;
 
-   NtFreeVirtualMemory (NtCurrentProcess (),
+   return NtFreeVirtualMemory (NtCurrentProcess (),
                        (PVOID)ProcessParameters,
                        &RegionSize,
                        MEM_RELEASE);
@@ -254,7 +254,7 @@ RtlDeNormalizeProcessParams(PRTL_USER_PROCESS_PARAMETERS Params)
 {
    if (Params && (Params->Flags & PPF_NORMALIZED))
      {
-       DENORMALIZE(Params->CurrentDirectoryName.Buffer, Params);\r
+       DENORMALIZE(Params->CurrentDirectoryName.Buffer, Params);
        DENORMALIZE(Params->DllPath.Buffer, Params);
        DENORMALIZE(Params->ImagePathName.Buffer, Params);
        DENORMALIZE(Params->CommandLine.Buffer, Params);
@@ -277,7 +277,7 @@ RtlNormalizeProcessParams(PRTL_USER_PROCESS_PARAMETERS Params)
 {
    if (Params && !(Params->Flags & PPF_NORMALIZED))
      {
-       NORMALIZE(Params->CurrentDirectoryName.Buffer, Params);\r
+       NORMALIZE(Params->CurrentDirectoryName.Buffer, Params);
        NORMALIZE(Params->DllPath.Buffer, Params);
        NORMALIZE(Params->ImagePathName.Buffer, Params);
        NORMALIZE(Params->CommandLine.Buffer, Params);