New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changelog button crashes the game if NewGRF contains relative folder #8886
Comments
So this is good... Due to the command used to create your tar file, it appears to contain a folder named '.'. Normally, this just means "current directory". OTTD then looks on this path and finds... its own changelog.txt, which it then crashes trying to display it (known issue, it's too big) |
Then, it won't crash anyway if I remove dots for my grf for now! Thanks for it. |
Actually, when the game tries to display any file in its readme viewer that is longer than 6,553 lines, it crashes with the same assertion as in the original comment: Line 672 in f9d24ff
This means that not only is OpenTTD's Fun fact: 6,553 * 10 < 65,536 < 6,554 * 10, which means the assertion is triggered based on the total number of vertical pixels, of which there are 10 per line. |
Need to finish #7786 or maybe at least pull some of the text file viewer improvements out of it so they can be committed. |
Version of OpenTTD
20210322-master-gf9d24ff45e
Expected result
Changelog button is disabled
Actual result
Changelog button is enabled and crashes if I click it:
Steps to reproduce
I recently updated my NewGRF and it contains a markdown file, which is named
changelog.md
It is awkward that Changelog button appears when
changelog.md
file exists, even though I refered a related codes atOpenTTD/src/textfile_gui.cpp
Line 385 in e5c3253
/newgrf
or/content_download/newgrf
folderThe text was updated successfully, but these errors were encountered: