Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-14025

[CMD] BAT/CMD processing missing end of line space when prompt echoed



    • Improvement
    • Resolution: Fixed
    • Minor
    • 0.4.15
    • Shell


      After creating the ReactOS API Test for cmd (cmd_rostest.exe) I started to investigate some of the failures and found that when Echo is On and the line with the prompt is echoed there should be a space at the end of the line which is missing in ReactOS. To see this compile the test api test using the "test_builtins.cmd" and one or the other of the EXP files. Rename the win_test_builtins.cmd.exp to test_builtins.cmd.exp for output that is good in Windows. Rename the ros_test_builtins.cmd.exp to test_builtins.cmd.exp for output that is good in ReactOS. Hopefully now there is enough information for a developer to fix this problem. Thanks.

      Edit: The error messages are misleading because it appears that the "compare" routine cannot handle the @xxxx@ substitutions correctly and I believe that this can be improved. Also, the error line numbers refer to the lines in the EXP output file and I would have expected them to refer to the line number in the input CMD file. Note: My guess is that the EXP file represents the Expected output.

      Edit2: The MSVC compiled version of cmd.exe will mostly fail with only 14 tests run and 3 failures, but the GCC compiled version will have 50 tests run with 0 failures.


        1. After_SG_Patch.txt
          4 kB
        2. batch07.c.patch
          0.6 kB
        3. batch08_c.patch
          0.5 kB
        4. cmd_winetest_for_ros.exe
          54 kB
        5. cmd_winetest_for_win.exe
          54 kB
        6. ros_test_builtins.cmd.exp
          0.7 kB
        7. test_builtins.cmd
          0.8 kB
        8. win_test_builtins.cmd.exp
          0.8 kB

        Issue Links



              hbelusca hbelusca
              DougLyons DougLyons
              3 Vote for this issue
              3 Start watching this issue