Skip to content

Commit ba5f215

Browse files
authored
Fix pqcheck and pqrepair on Windows (#17210)
A recent change to pqheck, attempted to address an issue where the pqcheck would not on Windows mahcines when located in a folder containing a space, such as "C:\program files\elastic\logstash". While this fixed an issue with spaces in folders, it introduced a new issue related to Java options, and the pqcheck was still unable to run on Windows. This PR attempts to address the issue, by removing the quotes around the Java options, which caused the option parsing to fail, and instead removes the explicit setting of the classpath - the use of `set CLASSPATH=` in the `:concat` function is sufficient to set the classpath, and should also fix the spaces issue Fixes: #17209
1 parent 1e06eea commit ba5f215

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Diff for: bin/pqcheck.bat

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ for %%i in ("%LS_HOME%\logstash-core\lib\jars\*.jar") do (
1616
call :concat "%%i"
1717
)
1818

19-
"%JAVACMD%" "%JAVA_OPTS%" -cp "%CLASSPATH%" org.logstash.ackedqueue.PqCheck %*
19+
"%JAVACMD%" %JAVA_OPTS% org.logstash.ackedqueue.PqCheck %*
2020

2121
:concat
2222
IF not defined CLASSPATH (

Diff for: bin/pqrepair.bat

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ for %%i in ("%LS_HOME%\logstash-core\lib\jars\*.jar") do (
1616
call :concat "%%i"
1717
)
1818

19-
"%JAVACMD%" %JAVA_OPTS% -cp "%CLASSPATH%" org.logstash.ackedqueue.PqRepair %*
19+
"%JAVACMD%" %JAVA_OPTS% org.logstash.ackedqueue.PqRepair %*
2020

2121
:concat
2222
IF not defined CLASSPATH (

0 commit comments

Comments
 (0)