Skip to content

Conversation

ayanamist
Copy link

在MIUI上发现,各个network的available和lost是互相独立的,会出现cellular available -> wifi available -> cellular unavailable -> cellular available这样的时序,按现有代码,cellular的变化会污染wifi的结果,导致wifi状态下dns却改成了cellular的,导致网络不通。没有用户报告的原因是在所有dns都不通时会默认去用default nameserver,但对于wifi是公司网络且需要公司内部dns解析场景,就会导致页面无法打开。

这里重新实现了dns感知机制,将每个network的dns状况单独保存,并按自定义的优先级在多个network之间获取dns,来规避这个问题。

@wwqgtxx wwqgtxx merged commit 61093eb into MetaCubeX:main Jun 29, 2025
1 check passed
@ayanamist ayanamist deleted the feature_dns branch June 29, 2025 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants