linker - How to catch UnsatisifiedLinkError when using NDK-built library in an Android app? -


I have an Android project that has a class using JNI to draw the value of C function; C function can be used as NDK Was built in the library. The value returned from the C function is used to initialize one variable within a class when its first load. It works fine however, I also want to work when the library is unavailable by providing a default value. So im using something like this:

  stable native string getstring (); Static {try {System.loadLibrary ("Library"); NAME = getstring (); } Hold (exception e) {NAME = "default"; }}  

Despite being caught, I'm still getting dissatisfied links when I try to run this code with the library why am I not being an exception? What am i doing

unsatisfied link error exception . The dissatisfied link enters is the hierarchy:

  throbble-> error-> Enter the unsatisfied link  

You better hold enter the dissatisfied link if you want to handle it.


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -