Buggy code:
List customPaths = ( ( List ) ( NativeLibrary . searchPaths . get ( libraryName ) ) ) ; if ( customPaths != null ) { synchronized ( customPaths ) { searchPath . addAll ( 0 , customPaths ) ; } } if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Adding<seq2seq4repair_space>paths<seq2seq4repair_space>from<seq2seq4repair_space>jna.library.path:<seq2seq4repair_space>" + ( System . getProperty ( "jna.library.path" ) ) ) ) ; } searchPath . addAll ( NativeLibrary . initPaths ( "jna.library.path" ) ) ; String libraryPath = NativeLibrary . findLibraryPath ( libraryName , searchPath ) ; long handle = 0 ; try { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Trying<seq2seq4repair_space>" + libraryPath ) ) ; } handle = Native . open ( libraryPath , openFlags ) ; } catch ( UnsatisfiedLinkError e ) { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Adding<seq2seq4repair_space>system<seq2seq4repair_space>paths:<seq2seq4repair_space>" + ( NativeLibrary . librarySearchPath ) ) ) ; } searchPath . addAll ( NativeLibrary . librarySearchPath ) ; } try { if ( handle == 0 ) { libraryPath = NativeLibrary . findLibraryPath ( libraryName , searchPath ) ; if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Trying<seq2seq4repair_space>" + libraryPath ) ) ; } handle = Native . open ( libraryPath , openFlags ) ; if ( handle == 0 ) { throw new UnsatisfiedLinkError ( ( ( "Failed<seq2seq4repair_space>to<seq2seq4repair_space>load<seq2seq4repair_space>library<seq2seq4repair_space>'" + libraryName ) + "'" ) ) ; } } } catch ( UnsatisfiedLinkError e ) { if ( Platform . isAndroid ( ) ) { try { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Preload<seq2seq4repair_space>(via<seq2seq4repair_space>System.loadLibrary)<seq2seq4repair_space>" + libraryName ) ) ; } System . loadLibrary ( libraryName ) ; handle = Native . open ( libraryPath , openFlags ) ; } catch ( UnsatisfiedLinkError e2 ) { e = e2 ; } } else if ( ( Platform . isLinux ( ) ) || ( Platform . isFreeBSD ( ) ) ) { if ( Native . DEBUG_LOAD ) { System . out . println ( "Looking<seq2seq4repair_space>for<seq2seq4repair_space>version<seq2seq4repair_space>variants" ) ; } libraryPath = NativeLibrary . matchLibrary ( libraryName , searchPath ) ; if ( libraryPath != null ) { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Trying<seq2seq4repair_space>" + libraryPath ) ) ; } try { handle = Native . open ( libraryPath , openFlags ) ; } catch ( UnsatisfiedLinkError e2 ) { e = e2 ; } } } else if ( ( Platform . isMac ( ) ) && ( ! ( libraryName . endsWith ( ".dylib" ) ) ) ) { if ( Native . DEBUG_LOAD ) { System . out . println ( "Looking<seq2seq4repair_space>for<seq2seq4repair_space>matching<seq2seq4repair_space>frameworks" ) ; } libraryPath = NativeLibrary . matchFramework ( libraryName ) ; if ( libraryPath != null ) { try { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Trying<seq2seq4repair_space>" + libraryPath ) ) ; } handle = Native . open ( libraryPath , openFlags ) ; } catch ( UnsatisfiedLinkError e2 ) { e = e2 ; } } } else if ( ( Platform . isWindows ( ) ) && ( ! isAbsolutePath ) ) { if ( Native . DEBUG_LOAD ) { System . out . println ( "Looking<seq2seq4repair_space>for<seq2seq4repair_space>lib-<seq2seq4repair_space>prefix" ) ; } libraryPath = NativeLibrary . findLibraryPath ( ( "lib" + libraryName ) , searchPath ) ; if ( libraryPath != null ) { if ( Native . DEBUG_LOAD ) { System . out . println ( ( "Trying<seq2seq4repair_space>" + libraryPath ) ) ; } try { handle = Native . open ( libraryPath , openFlags ) ; } catch ( UnsatisfiedLinkError e2 ) { e = e2 ; } } } if ( handle == 0 ) { try { File embedded = Native . extractFromResourcePath ( libraryName , ( ( ClassLoader ) ( options . get ( OPTION_CLASSLOADER ) ) ) ) ; <START_BUG> handle = Native . open ( embedded . getAbsolutePath ( ) ) ; <END_BUG> libraryPath = embedded . getAbsolutePath ( ) ; if ( Native . isUnpacked ( embedded ) ) { Native . deleteLibrary ( embedded ) ; } } catch ( IOException e2 ) { e = new UnsatisfiedLinkError ( e2 . getMessage ( ) ) ; } } if ( handle == 0 ) { throw new UnsatisfiedLinkError ( ( ( ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>load<seq2seq4repair_space>library<seq2seq4repair_space>'" + libraryName ) + "':<seq2seq4repair_space>" ) + ( e . getMessage ( ) ) ) ) ; } } if ( Native . DEBUG_LOAD ) { System . out . println ( ( ( ( "Found<seq2seq4repair_space>library<seq2seq4repair_space>'" + libraryName ) + "'<seq2seq4repair_space>at<seq2seq4repair_space>" ) + libraryPath ) ) ; } return new NativeLibrary ( libraryName , libraryPath , handle , options ) ; } static String matchFramework ( String libraryName ) { } private String getLibraryName ( String libraryName ) { } public static final NativeLibrary getInstance ( String libraryName ) { } public static final NativeLibrary getInstance ( String libraryName , ClassLoader classLoader ) { } public static final NativeLibrary getInstance ( String libraryName , Map options ) { } public static final synchronized NativeLibrary getProcess ( ) { } public static final synchronized NativeLibrary getProcess ( Map options ) { } public static final void addSearchPath ( String libraryName , String path ) { } public Function getFunction ( String functionName ) { } Function getFunction ( String name , Method method ) { } public Function getFunction ( String functionName , int callFlags ) { } public Function getFunction ( String functionName , int callFlags , String encoding ) { } public Map getOptions ( ) { } public Pointer getGlobalVariableAddress ( String symbolName ) { } long getSymbolAddress ( String name ) { } public String toString ( ) { } public String getName ( ) { } public File getFile ( ) { } protected void finalize ( ) { }

Fix:
handle = Native . open ( embedded . getAbsolutePath ( ) , openFlags ) ;