Skip to content

Commit

Permalink
update: commons-compress 1.26.1
Browse files Browse the repository at this point in the history
  • Loading branch information
cssxsh committed Apr 27, 2024
1 parent 19165a1 commit 6f70522
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ repositories {
dependencies {
api("com.github.jknack:handlebars:4.3.1")
api("org.seleniumhq.selenium:selenium-java:4.18.1")
implementation("org.apache.commons:commons-compress:1.26.0")
implementation("org.apache.commons:commons-compress:1.26.1")
implementation("org.tukaani:xz:1.9")
implementation("me.him188:kotlin-jvm-blocking-bridge-runtime:3.0.0-180.1")
testImplementation(kotlin("test"))
Expand Down
12 changes: 6 additions & 6 deletions src/main/kotlin/xyz/cssxsh/selenium/SeleniumInit.kt
Original file line number Diff line number Diff line change
Expand Up @@ -688,7 +688,7 @@ internal fun setupFirefoxDriver(folder: File): RemoteWebDriverSupplier {
.let(::GzipCompressorInputStream)
.let(::TarArchiveInputStream)
.use { input ->
val entry = input.nextTarEntry
val entry = input.nextEntry
driver.parentFile.mkdirs()
driver.outputStream().use { output ->
input.copyTo(output)
Expand Down Expand Up @@ -910,7 +910,7 @@ internal fun setupFirefox(folder: File, version: String): File {
pack.writeBytes(bytes)

try {
SevenZFile(pack).use { input ->
SevenZFile.builder().setFile(pack).get().use { input ->
for (entry in input.entries) {
if (entry.isDirectory) continue
// println(entry.name)
Expand Down Expand Up @@ -957,7 +957,7 @@ internal fun setupFirefox(folder: File, version: String): File {
.let(::TarArchiveInputStream)
.use { input ->
while (true) {
val entry = input.nextTarEntry ?: break
val entry = input.nextEntry ?: break
if (entry.isFile.not()) continue
if (input.canReadEntryData(entry).not()) continue
val target = folder.resolve(entry.name)
Expand Down Expand Up @@ -1145,7 +1145,7 @@ internal fun setupChromium(folder: File, version: String): File {
val pack = download(urlString = url, folder = folder, filename = url.substringAfterLast('/'))

try {
SevenZFile(pack).use { input ->
SevenZFile.builder().setFile(pack).get().use { input ->
for (entry in input.entries) {
if (entry.isDirectory) continue
val target = folder.resolve(entry.name)
Expand Down Expand Up @@ -1184,7 +1184,7 @@ internal fun setupChromium(folder: File, version: String): File {
.let(::TarArchiveInputStream)
.use { input ->
while (true) {
val entry = input.nextTarEntry ?: break
val entry = input.nextEntry ?: break
if (entry.isFile.not()) continue
if (input.canReadEntryData(entry).not()) continue
val target = folder.resolve(entry.name)
Expand Down Expand Up @@ -1220,7 +1220,7 @@ internal fun setupChromium(folder: File, version: String): File {
.let(::TarArchiveInputStream)
.use { input ->
while (true) {
val entry = input.nextTarEntry ?: break
val entry = input.nextEntry ?: break
if (entry.isFile.not()) continue
if (input.canReadEntryData(entry).not()) continue
val target = setup.resolve(entry.name)
Expand Down

0 comments on commit 6f70522

Please sign in to comment.