Skip to content

Commit

Permalink
Fix logstash.bat not setting exit code (elastic#12948)
Browse files Browse the repository at this point in the history
This PR makes the Windows logstash.bat exit with the last %ERRORLEVEL% at the end, so that any error in running Logstash will get propagated back to the command line.

Before this change, logstash.bat would always exit with code 0 - success (when doing cmd.exe /C logstash.bat), even if the java.exe process exited with a non-zero code (e.g. due to Logstash throwing an error at runtime).
  • Loading branch information
dionrhys authored Jun 21, 2021
1 parent d2c68fc commit 1f9ef97
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions bin/logstash.bat
Original file line number Diff line number Diff line change
Expand Up @@ -84,3 +84,4 @@ goto :eof

:end
endlocal
exit /B %ERRORLEVEL%

0 comments on commit 1f9ef97

Please sign in to comment.