-
-
Notifications
You must be signed in to change notification settings - Fork 606
Description
General description of bug:
When my ISP was working on some problems (i had no internet), i decided to launch fastfetch.
Surprisingly, it hanged for 10 seconds and only then gave me system information.
After some code digging, i realized that it happens only on Linux systems when interface is up, but there is no internet connection.
It all happens because of function getDomainName() in src/util/platform/FFPlatform_unix.c, it tries to resolve system hostname by requesting it from local resolver.
Resolver, that thinks there is internet connection, tries to request system hostname from more authoritative resolver (system-wide DNS, i think?), and it hangs until connection times out.
This issue doesn't happen when there is <hostname> 127.0.0.1 record in /etc/hosts, but according to my observations this is mostly not set.
- What happened: fastfetch hangs for 5-10 seconds when interface is up, but there is no internet connection
- What should happen: fastfetch... doesn't hang?
- Did it work in an older version: 1.12.2 (openSUSE Tumbleweed repos)
- Where did you get the binary: Built from source, openSUSE Tumbleweed repos
- Does this issue still occurs in the latest dev build? Yes
- Way to reproduce (hacky): Pull out the ethernet cable from router and start fastfetch immediately. (Works for me because router is near)
This can be not fastfetch issue, but resolving this somehow will be great.
Removed "helpful info" part because of irrelevance to the issue.