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

Don't show warnings in log when scanning for files in non-existent dirs #2266

Merged
merged 1 commit into from
Jan 5, 2023

Conversation

olanti-p
Copy link
Contributor

@olanti-p olanti-p commented Dec 31, 2022

Summary

SUMMARY: Infrastructure "Don't show warnings in log when scanning for files in non-existent dirs"

Purpose of change

There are warnings about missing directories in debug.log when game tries to load data from nonexistent user dirs:

15:11:02.060 WARNING : opendir [./user_dir/sound/] failed with "No such file or directory".
15:11:02.060 WARNING : opendir [./user_dir/gfx/] failed with "No such file or directory".
15:11:02.060 INFO : Number of render drivers on your system: 3
15:11:02.060 INFO : Render driver: 0/opengl
15:11:02.060 INFO : Render driver: 1/opengles2
15:11:02.060 INFO : Render driver: 2/software
15:11:02.073 WARNING : opendir [./user_dir/mods/] failed with "No such file or directory".

These are entirely benign, but the word "failed" seems to be an attention grabber whenever people try to figure out why their game has broken.

Describe the solution

If folder does not exist, just return an empty list.

@github-actions github-actions bot added the src changes related to source code. label Dec 31, 2022
@Coolthulhu Coolthulhu self-assigned this Jan 4, 2023
@Coolthulhu Coolthulhu merged commit 7d0d5d8 into cataclysmbnteam:upload Jan 5, 2023
@olanti-p olanti-p deleted the silence-lack-of-folder branch August 17, 2023 02:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
src changes related to source code.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants