summaryrefslogtreecommitdiffstats
path: root/editor/export_template_manager.cpp
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2017-11-25 00:07:54 -0300
committerJuan Linietsky <reduzio@gmail.com>2017-11-25 00:09:40 -0300
commitbc2e8d99e5ae0dbd69e712cc71da3033f5f30139 (patch)
treed836011e3d5873e3ceea328ea3100f3c7719ab99 /editor/export_template_manager.cpp
parent7dfba3cda9f13427f9f10a6eefbec52aef62274c (diff)
downloadredot-engine-bc2e8d99e5ae0dbd69e712cc71da3033f5f30139.tar.gz
Made Vector::ptrw explicit for writing, compiler was sometimes using the wrong function,
leading to unnecesary copy on writes and reduced performance.
Diffstat (limited to 'editor/export_template_manager.cpp')
-rw-r--r--editor/export_template_manager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/export_template_manager.cpp b/editor/export_template_manager.cpp
index d208bbe662..2aad4774b0 100644
--- a/editor/export_template_manager.cpp
+++ b/editor/export_template_manager.cpp
@@ -207,7 +207,7 @@ void ExportTemplateManager::_install_from_file(const String &p_file) {
//read
unzOpenCurrentFile(pkg);
- ret = unzReadCurrentFile(pkg, data.ptr(), data.size());
+ ret = unzReadCurrentFile(pkg, data.ptrw(), data.size());
unzCloseCurrentFile(pkg);
String data_str;
@@ -277,7 +277,7 @@ void ExportTemplateManager::_install_from_file(const String &p_file) {
//read
unzOpenCurrentFile(pkg);
- unzReadCurrentFile(pkg, data.ptr(), data.size());
+ unzReadCurrentFile(pkg, data.ptrw(), data.size());
unzCloseCurrentFile(pkg);
print_line(fname);