Skip to content

Commit

Permalink
adjust api to JDK 21
Browse files Browse the repository at this point in the history
  • Loading branch information
infeo committed Aug 4, 2023
1 parent c2588b1 commit fa3ccda
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
10 changes: 4 additions & 6 deletions jfuse-api/src/main/java/org/cryptomator/jfuse/api/Fuse.java
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public abstract class Fuse implements AutoCloseable {
/**
* The memory session associated with the lifecycle of this Fuse instance.
*/
protected final Arena fuseArena = Arena.openShared();
protected final Arena fuseArena = Arena.ofShared();

/**
* The file system operations invoked by this FUSE file system.
Expand Down Expand Up @@ -156,11 +156,9 @@ void waitForMountingToComplete(Path mountPoint, Future<Integer> fuseLoop) throws
@Blocking
private int fuseLoop(FuseMount mount) {
AtomicInteger result = new AtomicInteger();
fuseArena.scope().whileAlive(() -> {
int r = mount.loop();
result.set(r);
});
return result.get();
int r = mount.loop();
result.set(r);
return r;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.10.1</version>
<configuration>
<release>20</release>
<release>21</release>
<encoding>UTF-8</encoding>
<showWarnings>true</showWarnings>
<compilerArgs>
Expand Down

0 comments on commit fa3ccda

Please sign in to comment.