You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 13:10:58 +00:00
Fix _File::get_buffer length always set to p_length
This commit is contained in:
@@ -1334,7 +1334,7 @@ Vector<uint8_t> _File::get_buffer(int p_length) const {
|
|||||||
ERR_FAIL_COND_V(len < 0, Vector<uint8_t>());
|
ERR_FAIL_COND_V(len < 0, Vector<uint8_t>());
|
||||||
|
|
||||||
if (len < p_length) {
|
if (len < p_length) {
|
||||||
data.resize(p_length);
|
data.resize(len);
|
||||||
}
|
}
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
|
|||||||
Reference in New Issue
Block a user