Better solution for the previous fix.

This commit is contained in:
Relintai 2024-11-14 01:06:33 +01:00
parent 78534d1564
commit d75d3591ed
3 changed files with 6 additions and 1 deletions

View File

@ -5161,6 +5161,10 @@ String::String(const CharType *p_str) {
copy_from(p_str); copy_from(p_str);
} }
String::String(const Char16String &p_str) {
copy_from(p_str.ptr());
}
String::String(const char *p_str, int p_clip_to_len) { String::String(const char *p_str, int p_clip_to_len) {
copy_from(p_str, p_clip_to_len); copy_from(p_str, p_clip_to_len);
} }

View File

@ -569,6 +569,7 @@ public:
String(const char *p_str); String(const char *p_str);
String(const wchar_t *p_str); String(const wchar_t *p_str);
String(const CharType *p_str); String(const CharType *p_str);
String(const Char16String &p_str);
String(const char *p_str, int p_clip_to_len); String(const char *p_str, int p_clip_to_len);
String(const wchar_t *p_str, int p_clip_to_len); String(const wchar_t *p_str, int p_clip_to_len);
String(const CharType *p_str, int p_clip_to_len); String(const CharType *p_str, int p_clip_to_len);

View File

@ -2983,7 +2983,7 @@ Error OS_Windows::execute(const String &p_path, const List<String> &p_arguments,
CloseHandle(pipe[1]); CloseHandle(pipe[1]);
} }
ERR_FAIL_COND_V_MSG(ret == 0, ERR_CANT_FORK, "Could not create child process: " + String((wchar_t *) modstr.ptr())); ERR_FAIL_COND_V_MSG(ret == 0, ERR_CANT_FORK, "Could not create child process: " + String(modstr));
if (p_blocking) { if (p_blocking) {
if (r_pipe) { if (r_pipe) {