diff --git a/extensions/filedialogs/src/arc/filedialogs/FileDialogs.java b/extensions/filedialogs/src/arc/filedialogs/FileDialogs.java index 97a1d272..c807d783 100644 --- a/extensions/filedialogs/src/arc/filedialogs/FileDialogs.java +++ b/extensions/filedialogs/src/arc/filedialogs/FileDialogs.java @@ -48,7 +48,7 @@ public static void loadNatives() throws UnsatisfiedLinkError{ env->ReleaseStringChars(obj_defaultPathAndFile, defaultPathAndFile); env->ReleaseStringChars(obj_filterDescription, filterDescription); - return env->NewString((jchar*)result, wcslen(result)); + return result == NULL ? NULL : env->NewString((jchar*)result, wcslen(result)); #else char* title = (char*)env->GetStringUTFChars(obj_title, 0); char* defaultPathAndFile = (char*)env->GetStringUTFChars(obj_defaultPathAndFile, 0); @@ -110,7 +110,7 @@ public static void loadNatives() throws UnsatisfiedLinkError{ env->ReleaseStringChars(obj_defaultPathAndFile, defaultPathAndFile); env->ReleaseStringChars(obj_filterDescription, filterDescription); - return env->NewString((jchar*)result, wcslen(result)); + return result == NULL ? NULL : env->NewString((jchar*)result, wcslen(result)); #else char* title = (char*)env->GetStringUTFChars(obj_title, 0); diff --git a/natives/natives-filedialogs/libs/arc-filedialogs.dll b/natives/natives-filedialogs/libs/arc-filedialogs.dll index 16d736fb..462ca1e1 100755 Binary files a/natives/natives-filedialogs/libs/arc-filedialogs.dll and b/natives/natives-filedialogs/libs/arc-filedialogs.dll differ diff --git a/natives/natives-filedialogs/libs/arc-filedialogs64.dll b/natives/natives-filedialogs/libs/arc-filedialogs64.dll index f730007e..2a7383d2 100755 Binary files a/natives/natives-filedialogs/libs/arc-filedialogs64.dll and b/natives/natives-filedialogs/libs/arc-filedialogs64.dll differ