Skip to content
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

Trying to open a project crashes godot if gui/theme/default_theme_scale project setting is set to NAN. #81038

Closed
ghost opened this issue Aug 27, 2023 · 2 comments

Comments

@ghost
Copy link

ghost commented Aug 27, 2023

Godot version

v4.2.dev3.official.013e8e3af

System information

Windows 10.0.19045 - GLES3 (Compatibility)

Issue description

Setting gui/theme/default_theme_scale project setting to NAN (by typing NAN into the field in the Godot editor) makes a project crash and spam the console with the following errors when it is ran:

USER ERROR: ImageLoaderSVG: Couldn't set target on ThorVG canvas.
   at: create_image_from_utf8_buffer (modules/svg/image_loader_svg.cpp:113)
USER ERROR: Failed generating icon, unsupported or invalid SVG data in default theme.
   at: generate_icon (scene/resources/default_theme/default_theme.cpp:92)

Additionally, closing the editor without changing the setting back makes the project virtually non-openable, by crashing the editor every time it tries to open the project.

Steps to reproduce

  1. Create a new project.
  2. Set gui/theme/default_theme_scale project setting to NAN (by typing NAN in).
  3. Try to run the project.
  4. Close the editor.
  5. Try to open the project again.

Minimal reproduction project

Warning: non-openable because of the crash.
default_theme_scale_nan_test.zip

@AThousandShips
Copy link
Member

Can this still be replicated after #81076?

@akien-mga
Copy link
Member

Fixed by #81076.

It can likely be reproduced from code by setting nan manually to that project setting, but I'm not sure we want to go that far into preventing users from shooting themselves in the foot :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants