[Bug 49982] New: A '(call )' line does not reset %ERRORLEVEL% to 0

WineHQ Bugzilla wine-bugs at winehq.org
Sun Oct 11 11:07:19 CDT 2020


https://bugs.winehq.org/show_bug.cgi?id=49982

            Bug ID: 49982
           Summary: A '(call )' line does not reset %ERRORLEVEL% to 0
           Product: Wine
           Version: 5.18
          Hardware: x86-64
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: cmd
          Assignee: wine-bugs at winehq.org
          Reporter: aa1ronham at gmail.com
      Distribution: ---

The following batch script:

```
@echo off

echo Initial error level: %errorlevel%
call missing
echo After bad call: %errorlevel%
(call )
echo After empty call: %errorlevel%
```

gives the following output under Wine:

```
Initial error level: 0
Can't recognize 'missing' as an internal or external command, or batch script.
After bad call: 1
After empty call: 1
```


However, Windows 10 gives the following output:

```
Initial error level: 0
'missing' is not recognized as an internal or external command,
operable program or batch file.
After empty call: 1
After empty call: 0
```

It looks like the Windows cmd.exe resets %errorlevel% to 0 after a '(call )' is
executed, while Wine's cmd.exe leaves it unchanged.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list