fixed issue with leading path separator in some cases

This commit is contained in:
Robinson 2022-01-20 00:35:36 +01:00
parent 955e4f4294
commit 9463a09dd6
No known key found for this signature in database
GPG Key ID: 8E7DB78588BD6F5C
1 changed files with 5 additions and 1 deletions

View File

@ -86,7 +86,11 @@ class JvmExecOptions(private val executor: Executor, private val javaExecutable:
// classpath
val additionalClasspath = System.getProperty("java.class.path")
if (additionalClasspath.isNotEmpty()) {
builder.append(pathSeparator) // have to add a separator
if (count > 0) {
// have to add a separator
builder.append(pathSeparator)
}
builder.append(additionalClasspath)
}
}