mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 02:09:44 +02:00
Merge remote-tracking branch 'origin/GP-5225_dev747368_fix_fail_to_close_file.zip'
This commit is contained in:
commit
d65fd1f9f9
1 changed files with 5 additions and 4 deletions
|
@ -4,9 +4,9 @@
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
* You may obtain a copy of the License at
|
* You may obtain a copy of the License at
|
||||||
*
|
*
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
*
|
*
|
||||||
* Unless required by applicable law or agreed to in writing, software
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
@ -32,8 +32,8 @@ public class ZipFileSystemFactory
|
||||||
* Use "-Dghidra.file.formats.zip.ZipFileSystemFactory.USE_BUILTIN_ZIP_SUPPORT=true" jvm
|
* Use "-Dghidra.file.formats.zip.ZipFileSystemFactory.USE_BUILTIN_ZIP_SUPPORT=true" jvm
|
||||||
* startup option to disable use of 7zip libraries when opening zip filesystems.
|
* startup option to disable use of 7zip libraries when opening zip filesystems.
|
||||||
*/
|
*/
|
||||||
private static boolean USE_BUILTIN_ZIP_SUPPORT = Boolean
|
private static boolean USE_BUILTIN_ZIP_SUPPORT =
|
||||||
.getBoolean("ghidra.file.formats.zip.ZipFileSystemFactory.USE_BUILTIN_ZIP_SUPPORT");
|
Boolean.getBoolean("ghidra.file.formats.zip.ZipFileSystemFactory.USE_BUILTIN_ZIP_SUPPORT");
|
||||||
|
|
||||||
private static final int START_BYTES_REQUIRED = 2;
|
private static final int START_BYTES_REQUIRED = 2;
|
||||||
|
|
||||||
|
@ -84,6 +84,7 @@ public class ZipFileSystemFactory
|
||||||
ZipFileSystemBuiltin.TEMPFILE_PREFIX, monitor);
|
ZipFileSystemBuiltin.TEMPFILE_PREFIX, monitor);
|
||||||
deleteZipFileWhenDone = true;
|
deleteZipFileWhenDone = true;
|
||||||
}
|
}
|
||||||
|
FSUtilities.uncheckedClose(byteProvider, null);
|
||||||
ZipFileSystemBuiltin fs = new ZipFileSystemBuiltin(targetFSRL, fsService);
|
ZipFileSystemBuiltin fs = new ZipFileSystemBuiltin(targetFSRL, fsService);
|
||||||
try {
|
try {
|
||||||
fs.mount(zipFile, deleteZipFileWhenDone, monitor);
|
fs.mount(zipFile, deleteZipFileWhenDone, monitor);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue