Fix memory leak

This commit is contained in:
Andrea Cavalli 2024-09-16 17:32:11 +02:00
parent 62e536e88f
commit 759e37558f

View File

@ -467,10 +467,12 @@ public class GrpcServer extends Server {
} }
private static void closeArenaSafe(Arena autoArena) { private static void closeArenaSafe(Arena autoArena) {
try { if (autoArena != null) {
autoArena.close(); try {
} catch (Exception ex2) { autoArena.close();
LOG.error("Failed to close arena", ex2); } catch (Exception ex2) {
LOG.error("Failed to close arena", ex2);
}
} }
} }