File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/main/java/com/github/luben/zstd/util Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ public enum Native {
13
13
;
14
14
15
15
private static final String nativePathOverride = "ZstdNativePath" ;
16
+ private static final String tempFolderOverride = "ZstdTempFolder" ;
16
17
private static final String libnameShort = "zstd-jni-" + ZstdVersion .VERSION ;
17
18
private static final String libname = "lib" + libnameShort ;
18
19
private static final String errorMsg = "Unsupported OS/arch, cannot find " +
@@ -83,7 +84,12 @@ public Void run() {
83
84
}
84
85
85
86
public static synchronized void load () {
86
- load (null );
87
+ String tempFolder = System .getProperty (tempFolderOverride );
88
+ if (tempFolder == null ) {
89
+ load (null );
90
+ } else {
91
+ load (new File (tempFolder ));
92
+ }
87
93
}
88
94
89
95
public static synchronized void load (final File tempFolder ) {
You can’t perform that action at this time.
0 commit comments