Merge pull request #19201 from neikeq/issue-13837

Mono: Fix MonoImage filename being set to an invalid path
This commit is contained in:
Ignacio Etcheverry 2018-05-27 17:19:13 +02:00 committed by GitHub
commit 97342e6985
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 4 deletions

View File

@ -33,9 +33,10 @@
#include <mono/metadata/mono-debug.h> #include <mono/metadata/mono-debug.h>
#include <mono/metadata/tokentype.h> #include <mono/metadata/tokentype.h>
#include "list.h" #include "core/list.h"
#include "os/file_access.h" #include "core/os/file_access.h"
#include "os/os.h" #include "core/os/os.h"
#include "core/project_settings.h"
#include "../godotsharp_dirs.h" #include "../godotsharp_dirs.h"
#include "gd_mono_class.h" #include "gd_mono_class.h"
@ -210,7 +211,7 @@ Error GDMonoAssembly::load(bool p_refonly) {
Vector<uint8_t> data = FileAccess::get_file_as_array(path); Vector<uint8_t> data = FileAccess::get_file_as_array(path);
ERR_FAIL_COND_V(data.empty(), ERR_FILE_CANT_READ); ERR_FAIL_COND_V(data.empty(), ERR_FILE_CANT_READ);
String image_filename(path); String image_filename = ProjectSettings::get_singleton()->globalize_path(path);
MonoImageOpenStatus status = MONO_IMAGE_OK; MonoImageOpenStatus status = MONO_IMAGE_OK;