Bound Contacts search copy and refresh source inventory

This commit is contained in:
liu weikai committed 2026-10-14 22:36:51 +08:00
1 parent fce8173b0a
commit 2fb8d4a0f5
2 files changed
+3 -2

No files matched your search

@@ -2,7 +2,7 @@
由 scripts/audit_nvs_access.mjs 扫描 ESP、共享 UI 和仓库 third_party 的 C/C++ 文件。只记录 NVS 函数、namespace/key/handle 实参和位置,不读取设备、不记录值/默认值/缓冲/分区名。不把最近的 nvs_open 自动推断为后续调用的 namespace;跨作用域句柄、宏和条件编译仍需人工核对。
扫描 1521 个源文件,找到 106 个候选调用,分布于 8 个文件。显式打开 15,键访问 45,其余为提交/关闭/清域。调用数不是独立配置数。
扫描 1522 个源文件,找到 106 个候选调用,分布于 8 个文件。显式打开 15,键访问 45,其余为提交/关闭/清域。调用数不是独立配置数。
这是源码入口清单,不是全部配置或硬件生效证明。系统 SDK、构建环境依赖、其他平台、函数指针/包装器实参以及复杂原始字符串不由此表自动覆盖。依赖库可单独调用 collectNvsAccesses 指定根目录审计;输出应单独记录其版本,不能写进与机器无关的仓库清单。
@@ -387,7 +387,8 @@ void refresh_node_card_data()
if (state.card_index >= state.card_entries.size()) state.card_index = 0;
state.card_mode = state.current_mode;
state.card_context_valid = true;
std::snprintf(state.card_query, sizeof(state.card_query), "%s", state.search_query);
std::snprintf(state.card_query, sizeof(state.card_query), "%.*s",
static_cast<int>(sizeof(state.card_query) - 1), state.search_query);
// Release full projections left by another mode; only one peer is hydrated.
state.total_items = state.card_entries.size();
hydrate_node_card();