From 40c0e1993aa28f580b9bf597abc8902b5d5c1e93 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Tue, 12 May 2015 09:12:18 -0300 Subject: Fixes problem parsing config files using ConfigFile --- core/io/config_file.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'core/io') diff --git a/core/io/config_file.cpp b/core/io/config_file.cpp index 95ae31f3dd..75388f514a 100644 --- a/core/io/config_file.cpp +++ b/core/io/config_file.cpp @@ -357,6 +357,7 @@ if (res!=-1 && res < min_pos) {\ } break; case MIN_OPEN: { int level=1; + end++; while(end Date: Mon, 18 May 2015 11:14:02 -0300 Subject: fix a compile error --- core/io/resource_format_xml.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/io') diff --git a/core/io/resource_format_xml.cpp b/core/io/resource_format_xml.cpp index 3e625ba6fd..ce648523f0 100644 --- a/core/io/resource_format_xml.cpp +++ b/core/io/resource_format_xml.cpp @@ -1374,7 +1374,7 @@ Error ResourceInteractiveLoaderXML::poll() { if (res.is_null()) { if (ResourceLoader::get_abort_on_missing_resources()) { - ERR_EXPLAIN(local_path+":"+itos(get_current_line())+": editor exported unexisting resource at: "+path); + ERR_EXPLAIN(local_path+":"+itos(get_current_line())+": editor exported nonexistent resource at: "+path); ERR_FAIL_V(error); } else { ResourceLoader::notify_load_error("Resource Not Found: "+path); @@ -1433,7 +1433,7 @@ Error ResourceInteractiveLoaderXML::poll() { if (res.is_null()) { if (ResourceLoader::get_abort_on_missing_resources()) { - ERR_EXPLAIN(local_path+":"+itos(get_current_line())+": referenced unexisting resource at: "+path); + ERR_EXPLAIN(local_path+":"+itos(get_current_line())+": referenced nonexistent resource at: "+path); ERR_FAIL_V(error); } else { ResourceLoader::notify_load_error("Resource Not Found: "+path); -- cgit v1.2.3 From 221443c5a2d174e52d391d15d5f1c6b5c9496d57 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Tue, 19 May 2015 21:36:35 -0300 Subject: more fixes -only refuse to load an older file if version major is different, fixes #1944 -fix drive letter default value, fixes #1939 --- core/io/resource_format_binary.cpp | 4 ++-- core/io/resource_format_xml.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'core/io') diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp index 3d7d2f2367..9fb17bcffb 100644 --- a/core/io/resource_format_binary.cpp +++ b/core/io/resource_format_binary.cpp @@ -861,7 +861,7 @@ void ResourceInteractiveLoaderBinary::open(FileAccess *p_f) { print_bl("minor: "+itos(ver_minor)); print_bl("format: "+itos(ver_format)); - if (ver_formatVERSION_MAJOR || (ver_major==VERSION_MAJOR && ver_minor>VERSION_MINOR)) { + if (ver_formatVERSION_MAJOR) { f->close(); ERR_EXPLAIN("File Format '"+itos(FORMAT_VERSION)+"."+itos(ver_major)+"."+itos(ver_minor)+"' is too new! Please upgrade to a a new engine version: "+local_path); @@ -968,7 +968,7 @@ String ResourceInteractiveLoaderBinary::recognize(FileAccess *p_f) { uint32_t ver_minor=f->get_32(); uint32_t ver_format=f->get_32(); - if (ver_formatVERSION_MAJOR || (ver_major==VERSION_MAJOR && ver_minor>VERSION_MINOR)) { + if (ver_formatVERSION_MAJOR) { f->close(); return ""; diff --git a/core/io/resource_format_xml.cpp b/core/io/resource_format_xml.cpp index ce648523f0..3c100d375a 100644 --- a/core/io/resource_format_xml.cpp +++ b/core/io/resource_format_xml.cpp @@ -1671,7 +1671,7 @@ void ResourceInteractiveLoaderXML::open(FileAccess *p_f) { int major = version.get_slice(".",0).to_int(); int minor = version.get_slice(".",1).to_int(); - if (major>VERSION_MAJOR || (major==VERSION_MAJOR && minor>VERSION_MINOR)) { + if (major>VERSION_MAJOR) { error=ERR_FILE_UNRECOGNIZED; ResourceLoader::notify_load_error(local_path+": File Format '"+version+"' is too new. Please upgrade to a newer engine version."); -- cgit v1.2.3