If a thread sets a shutdown hook using Runtime.getRuntime().addShutdownHook(); calls via jna the method: