Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

oomeow
Copy link
Contributor

@oomeow oomeow commented Oct 8, 2025

Closes: #4864

  • 修复自动关闭 Tun 模式操作导致应用卡死

  • 通过系统托盘启用Tun模式前,检查用户和服务状态
    如果用户为 非管理员,并且 服务未安装,弹出系统通知消息,告知用户需要安装服务模式

@oomeow oomeow requested review from Tunglies and wonfen October 8, 2025 06:56
@Tunglies
Copy link
Contributor

Tunglies commented Oct 8, 2025

在勿打扰 / 未授予系统通知权限,用户无法知道发生了什么。或许可以触发安装服务、开启TUN,或者托盘禁用?

@oomeow oomeow marked this pull request as draft October 10, 2025 12:29
@oomeow oomeow force-pushed the fix/toggle-tun-mode branch from 05fc78e to 8cc9d06 Compare October 11, 2025 12:33
@oomeow
Copy link
Contributor Author

oomeow commented Oct 11, 2025

@Tunglies 从系统托盘Tun模式进行触发点击服务安装的方法涉及的地方修改太多了,需要处理不同的服务状态,重启内核操作,我认为让用户在前端侧安装服务模式可以更直观的观察服务/内核状态

@oomeow oomeow marked this pull request as ready for review October 13, 2025 12:49
@Tunglies
Copy link
Contributor

Tunglies commented Oct 13, 2025

启用 TUN,退出程序,删除 socket,进入,提示TUN不可用自动关闭,未见卡死,内核正常启动与测速。

缺陷,从不可用TUN fallback时内核正常启动,但无法使用代理,手动执行开关代理无作用,重启程序后代理正常。macos。


/// Toggle TUN mode on/off
pub async fn toggle_tun_mode(not_save_file: Option<bool>) {
if !cmd::system::is_admin().unwrap_or_default()
Copy link
Contributor

@Tunglies Tunglies Oct 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Image 无实际服务可用时快速操作会虚假状态,再次单击可刷新正常。或许我们应该在托盘那边参考是否管理员,服务可用的方式对 TUN 托盘菜单进行禁用翻转?

@Tunglies
Copy link
Contributor

现在 UI 安装服务后不会立即刷新页面状态,需要切换页面几次。

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.

[BUG] 打开Tun模式。软件卡死。报错见图。

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.