diff --git a/client/Android/FreeRDPCore/jni/android_freerdp.c b/client/Android/FreeRDPCore/jni/android_freerdp.c index 6a31ebc0e..91ad73c3e 100644 --- a/client/Android/FreeRDPCore/jni/android_freerdp.c +++ b/client/Android/FreeRDPCore/jni/android_freerdp.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include @@ -536,7 +537,10 @@ JNIEXPORT void JNICALL jni_freerdp_set_data_directory(JNIEnv *env, jclass cls, j const jbyte *directory = (*env)->GetStringUTFChars(env, jdirectory, NULL); free(settings->HomePath); + free(settings->ConfigPath); settings->HomePath = strdup(directory); + settings->ConfigPath = NULL; + freerdp_detect_paths(settings); (*env)->ReleaseStringUTFChars(env, jdirectory, directory); }