Rename JNI API: getOlmLibVersion() => getOlmLibVersionJni()
This commit is contained in:
parent
e63be97774
commit
b3c2015616
3 changed files with 7 additions and 4 deletions
|
@ -56,6 +56,9 @@ public class OlmManager {
|
|||
* Get the OLM lib version.
|
||||
* @return the lib version as a string
|
||||
*/
|
||||
public native String getOlmLibVersion();
|
||||
public String getOlmLibVersion(){
|
||||
return getOlmLibVersionJni();
|
||||
}
|
||||
public native String getOlmLibVersionJni();
|
||||
}
|
||||
|
||||
|
|
|
@ -465,14 +465,14 @@ JNIEXPORT jstring OLM_ACCOUNT_FUNC_DEF(signMessageJni)(JNIEnv *env, jobject thiz
|
|||
}
|
||||
|
||||
|
||||
JNIEXPORT jstring OLM_MANAGER_FUNC_DEF(getOlmLibVersion)(JNIEnv* env, jobject thiz)
|
||||
JNIEXPORT jstring OLM_MANAGER_FUNC_DEF(getOlmLibVersionJni)(JNIEnv* env, jobject thiz)
|
||||
{
|
||||
uint8_t majorVer=0, minorVer=0, patchVer=0;
|
||||
jstring returnValueStr=0;
|
||||
char buff[150];
|
||||
|
||||
olm_get_library_version(&majorVer, &minorVer, &patchVer);
|
||||
LOGD("## getOlmLibVersion(): Major=%d Minor=%d Patch=%d", majorVer, minorVer, patchVer);
|
||||
LOGD("## getOlmLibVersionJni(): Major=%d Minor=%d Patch=%d", majorVer, minorVer, patchVer);
|
||||
|
||||
snprintf(buff, sizeof(buff), " V%d.%d.%d", majorVer, minorVer, patchVer);
|
||||
returnValueStr = env->NewStringUTF((const char*)buff);
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
JNIEXPORT jstring OLM_MANAGER_FUNC_DEF(getOlmLibVersion)(JNIEnv *env, jobject thiz);
|
||||
JNIEXPORT jstring OLM_MANAGER_FUNC_DEF(getOlmLibVersionJni)(JNIEnv *env, jobject thiz);
|
||||
|
||||
// account creation/destruction
|
||||
JNIEXPORT void OLM_ACCOUNT_FUNC_DEF(releaseAccountJni)(JNIEnv *env, jobject thiz);
|
||||
|
|
Loading…
Reference in a new issue