mirror of
https://github.com/godotengine/godot.git
synced 2026-01-03 18:11:19 +03:00
Made Vector::ptrw explicit for writing, compiler was sometimes using the wrong function,
leading to unnecesary copy on writes and reduced performance.
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user