合并受阻
感谢提交 Pull Requests!如果您提交的PR已经开发完毕,请评论 "start build" 触发门禁,更多交互操作,请访问OpenHarmony社区支持命令清单。如果需要调整订阅PR、Issue的变更状态,请访问订阅链接。
Thanks for submitting the pull request. If your Pull Request has already been developed, you can leave a "start build" comment to trigger the gated system. For more commands, please visit OpenHarmony Command List. If you need to change the subscription of a Pull Request or Issue, please visit the link.


代码门禁未通过
您可以通过如下链接查看门禁报告:http://dcp.openharmony.cn/workbench/cicd/detail/6a9bdc9164650f998b1ccf30/runlist
静态检查:
| # | check type | result | report |
|---|---|---|---|
| 1 | codeCheck | pass | >>> |
编译测试:
| # | Device | build result | test result | package |
|---|---|---|---|---|
| 1 | hispark_taurus_LiteOS | success | success | >>> |
| 2 | hispark_taurus_Linux | success | NA | >>> |
| 3 | ohos-sdk | success | NA | >>> |
| 4 | dayu200 | success | success | >>> |
| 5 | dayu200_tdd | success | NA | >>> |
| 6 | hispark_pegasus | success | success | >>> |
| 7 | master_inner_build | failed(联合门禁失败) | NA | >>> |
| 8 | mac-sdk | success | NA | >>> |
| 9 | ohos-host_mini_tdd | success | NA | >>> |
| 10 | dayu600_7885 | success | success | >>> |
| 11 | x86_64_virt | success | NA | >>> |
| 12 | hispark_pegasus_3863 | success | success | >>> |


start build


部分构建失败,仅触发失败构建
门禁构建开始,包含代码编译【master_inner_build编译】,预计在60分钟内完成,门禁结果会同步发送到注册邮箱。您可以通过如下链接跟踪门禁进展:http://dcp.openharmony.cn/workbench/cicd/detail/6a9c18ec64650f998b2ee8fe/runlist


代码门禁未通过
您可以通过如下链接查看门禁报告:http://dcp.openharmony.cn/workbench/cicd/detail/6a9c18ec64650f998b2ee8fe/runlist
| # | Device | build result | package |
|---|---|---|---|
| 1 | master_inner_build | failed(pipeline running timeout) | >>> |


背景
init(PID 1)单线程,多处waitpid/strstr无超时/无判空,子进程挂起或 uevent 无 DEVNAME 即冻结/崩溃整机。本 PR 落地其中 3 项"高风险 × 小改动"修复 + 100% 分支覆盖单测。改动(5 文件,+125/−22,单笔 commit)
1. syncexec/DumpFdInfo waitpid 无超时(init_cmds.c)
SyncExecCommand(cfgsyncexec命令)与DumpFdInfo的waitpid(pid,&status,0)无超时,异常子进程挂起即冻结 init(违反 §3.2)。新增WaitPidTimeout(WNOHANG轮询 100ms,超时SIGKILL+收尸,返 -1);syncexec 30s、fd dump 5s。2. appspawn waitpid 无超时(init_service_manager.c)
StopAppSpawnBeforeRebootSIGTERM 后阻塞waitpid(appspawn),D 态/忽略 SIGTERM 则重启冻结。复用WaitPidTimeout(5s+SIGKILL),extern引用init_cmds.c中的共享定义——单一来源,不新增头文件。3. ueventd strstr NULL 解引用(ueventd.c)
HandleRequiredBlockDeviceNodes未判deviceName即strstr,块设备 uevent 不保证带 DEVNAME → NULL 解引用 → ramdiskueventd -b段错误、启动失败。增deviceName != NULL守卫;日志 NULL 打印"(null)"。11 折||链抽为表驱动IsRequiredPartitionName(非 static,行为不变,圈复杂度 ≤10)。测试(在既有文件中新增,100% 分支覆盖)
cmds_unittest.cppWaitPidTimeout_ChildExitsWaitPidTimeout_InvalidPidWaitPidTimeout_TimeoutKillWIFSIGNALED && SIGKILLueventd_event_unittest.cppIsRequiredPartitionName_MatchIsRequiredPartitionName_OtherMatchIsOtherPartitionName→ trueIsRequiredPartitionName_NoMatch验证
ninja -C out/rk3568 init init_unittest→LINK init+LINK init_unittest,0 error,0 warning。单测 ARM 架构,需 rk3568 设备/QEMU 运行。行为变更
约束遵循(AGENTS.md §3)
WNOHANG轮询。realloc(§编码规则)。Signed-off-by: chenjinxiang3 chenjinxiang3@huawei.com