diff options
author | Alin Gabriel Serdean <aserdean@ovn.org> | 2019-03-19 00:43:00 +0200 |
---|---|---|
committer | Alin Gabriel Serdean <aserdean@ovn.org> | 2019-04-03 17:47:29 +0300 |
commit | 241bc88a2dd76a80b9f8dcc572e82ebe1a265b29 (patch) | |
tree | 94c325e46802c673a2b1154c7e3ed087c9344694 /datapath-windows | |
parent | c4f8dc7a9c5c1802f6b185b2440f9245a719f73b (diff) | |
download | openvswitch-241bc88a2dd76a80b9f8dcc572e82ebe1a265b29.tar.gz |
checkpatch: Normalize exit code for Windows
Using python `sys.exit(-1)` on Windows produces mixed results.
Let's take the following results from different shells:
CMD
>python -c "import sys; sys.exit(-1)" & echo %errorlevel%
1
MSYS
$ python -c "import sys; sys.exit(-1)" && echo $?
0
WSL
$ python -c "import sys; sys.exit(-1)"; echo $?
255
this results in the following tests to fail:
checkpatch
10: checkpatch - sign-offs FAILED (checkpatch.at:32)
11: checkpatch - parenthesized constructs FAILED (checkpatch.at:32)
12: checkpatch - parenthesized constructs - for FAILED (checkpatch.at:32)
13: checkpatch - comments FAILED (checkpatch.at:32)
because of:
./checkpatch.at:32: exit code was 0, expected 255
This patch introduces a positive constant for the default exit code (1)
similar to other OVS utilities.
Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
Acked-by: Ben Pfaff <blp@ovn.org>
Acked-by: Aaron Conole <aconole@redhat.com>
Diffstat (limited to 'datapath-windows')
0 files changed, 0 insertions, 0 deletions