Repository navigation
fix: 重启接口确认进程真实拉起 - #15
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
目标
修复 relaunch 结果谎报:旧实现在
uiopenfork 成功即返回relaunched:true,rootless 实测进程并未出现。改动
uiopen结果不再等同于拉起成功:有界等待后按进程名判定真实结果,失败返回relaunched:false。idh_reap_child/idh_finish_child:有界回收替代裸waitpid(daemon 环境下 waitpid 阻塞约 24s)。uiopen确认未拉起时兜底idh_spawn_mobile(fork→setsid→setgid(501)/initgroups("mobile")/setuid(501)→execve 直启二进制)。rootless 上/var/jb/Applications手工安装的 jb 应用不在 SpringBoard 可启动集合里,uiopen返回 0 但不产生进程。idh_close_inherited_fds:fork 后关闭继承 fd,避免把 daemon socket/配置 fd 泄漏给目标进程。execve传最小环境。验证(双端真机,CI 包 45585559596 / 1.28.52)
relaunch→{"relaunched":true,"killed":["CryptoTestHost"],"ok":true},0.7s 返回,uiopen 路径;新进程 presence 注册后 tools/dump、tools/symbols/images、tools/files 均正常。relaunch→{"relaunched":true,"killed":[],"ok":true},约 28s 返回(uiopen 子进程自然超时后回收,兜底直启);新进程 pid 46278、uid=501、lstart 全新,注入后 presence 正常。随后tools/dump(ipa)完成并下载 188,930 字节 zip,内含 186,496 字节解密CryptoTestHost+ Info.plist。45585559596通过。