Merge pull request #39056 from rileylyman/tscn_newlines
Skip extra newline in .tscn when renaming dependency
This commit is contained in:
commit
43f60c94e8
1 changed files with 5 additions and 0 deletions
|
@ -838,6 +838,11 @@ Error ResourceLoaderText::rename_dependencies(FileAccess *p_f, const String &p_p
|
|||
f->seek(tag_end);
|
||||
|
||||
uint8_t c = f->get_8();
|
||||
if (c == '\n' && !f->eof_reached()) {
|
||||
// Skip first newline character since we added one
|
||||
c = f->get_8();
|
||||
}
|
||||
|
||||
while (!f->eof_reached()) {
|
||||
fw->store_8(c);
|
||||
c = f->get_8();
|
||||
|
|
Loading…
Add table
Reference in a new issue