Merge pull request #84934 from Faless/fix/file_get_buffer

[3.x] [Core] Fix `File.get_buffer` returning wrong length
This commit is contained in:
Rémi Verschelde 2023-12-08 15:41:39 +01:00
commit bfc4baa289
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -2177,7 +2177,7 @@ PoolVector<uint8_t> _File::get_buffer(int64_t p_length) const {
w.release(); w.release();
if (len < p_length) { if (len < p_length) {
data.resize(p_length); data.resize(len);
} }
return data; return data;