跳到主要内容

Claude Cage · 面向 Claude 的隔离开发环境,支持桌面工作台、多账号、远程部署与移动端连接。上游 Lee-xeo/Claude-Cage 完整源码镜像,非灵栈原创;主许可 MIT,第三方组件遵循各自许可。来源:https://github.com/Lee-xeo/Claude-Cage 。手动同步,不附带 Release 安装包。

浏览文件

0031-vz-stop-retain-owner.patch

24 行 · 749 B历史下载
1--- a/pkg/driver/vz/vz_driver_darwin.go
2+++ b/pkg/driver/vz/vz_driver_darwin.go
3@@ -574,7 +574,6 @@
4
5 func (l *LimaVzDriver) Stop(ctx context.Context) error {
6 logrus.Info("Shutting down VZ")
7- defer l.removePIDFile()
8
9 requested := false
10 if l.machine.CanRequestStop() {
11@@ -599,7 +598,12 @@
12
13 // The VM is never stopped forcibly with l.machine.Stop(): that does not give the guest
14 // a chance to stop cleanly, and may corrupt the disk.
15- return l.waitForStopped(gracefulStopTimeout)
16+ if err := l.waitForStopped(gracefulStopTimeout); err != nil {
17+ // Retain the owner record while the VM may still be running.
18+ return err
19+ }
20+ l.removePIDFile()
21+ return nil
22 }
23
24 func (l *LimaVzDriver) waitForStopped(timeout time.Duration) error {