yzy-15
48315978c7
fix: remove unnecessary empty check, fix indentation, remove redundant lock
...
P2-7: Remove callerBundleName.empty() check — GetNameForUid returning
ERR_OK implies a valid name was set, empty check is redundant.
P2-5: Fix indentation in AddFormTimerForMultiUpdate — added validation
code had 4 extra spaces, now matches surrounding code style.
P1-5: Remove mutex lock from ~FormProxyRegistry — with shared_ptr
management, destructor runs only when ref count is 0, meaning no
concurrent access is possible. weak_ptr::lock() returns nullptr
atomically. Keep death recipient cleanup (still needed to unregister
from IPC framework).
AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%]
Co-authored-by: opencode (glm-5.2) <ai@local>
Change-Id: I83aa22f357c03822f5a6f2ececb39b5cc2697850
Signed-off-by: yzy-15 <yuzhiyong6@h-partners.com >
2026-08-21 15:02:16 +08:00
yzy-15
71db7608b3
fix: resolve 32 code review issues from form_fwk audit
...
Concurrency fixes:
- P1-1: atTimerWakeUpTime_ change to std::atomic<int64_t>
- P1-2: reportDiskUseTimerId_ change to std::atomic<uint64_t>
- P1-3: merge HasRouterProxy check and map access into single lock scope
- P1-4: unsubscribe common event before clearing event handles map
- P1-5: remove death recipients before clearing in FormProxyRegistry destructor
- P1-7: limiterTimerReportId_ change to std::atomic<uint64_t>
- P1-8: protect CreateLimiterTimer check-create-store with mutex, validate CreateTimer return
- P1-9: hasCachedConfig_ change to std::atomic<bool>
- P1-10: isInitialized_ change to std::atomic<bool>, add lock in Init()
- P1-11: add mutex lock in LoadDataFromDb
Input validation fixes:
- P2-1/P2-2/P2-3: add size check before StringUtils::split[1] access
- P2-4: validate float params in FormSurfaceInfo::ReadFromParcel
- P2-5: add hour/minute range validation in UpdateTimerValue
- P2-6: check GetOsAccountLocalIdFromUid return value
- P2-7: add empty string check for callerBundleName
- P2-8: check GetFormLock return value, fail-closed
- P2-9: add callerToken null check in SetFormAddObserver/SetFormRemoveObserver
- P2-10: check GetFormRecord return value in AcquireProviderFormInfo
Integer/type fixes:
- P3-1: add errno check in ConvertStringToLongLong
- P3-2: add overflow check in ConvertStringToInt
- P3-3: change NANO_PER_SECOND to int64_t
Null pointer/uninitialized fixes:
- P4-1: add connect parameter null check in ConnectServiceAbilityWithUserId
- P4-2: initialize castFormsCount to 0
Resource management fixes:
- P5-1: check PushFormEvent return value in AddTaskToQueuePush
- P5-2: return false on runtime Init/InsertHapPath failure
- P5-3: replace shared_from_this with raw pointer in FormShareMgr destructor
Dead code removal:
- P7-1: remove unused IsDynamicTimerExpired with self-deadlock risk
Permission check:
- P6-1: add caller identity verification in UpdateSubscribeFormData
Low-risk fixes:
- P8-1: check RegisterBundleEventCallback return value
- P8-2: same as P3-2
Documentation:
- F4/F5: add lock behavior comments for DeleteRenderRecordByUid and SetCriticalFalseOnAllFormInvisible
AI[100%] Human Fixed[0%] Human[0%] AI Adopted[100%]
Co-authored-by: opencode (glm-5.2) <ai@local>
Change-Id: I07c6b44bedb54aae4f3706ca2376ebee13b04bc5
Signed-off-by: yzy-15 <yuzhiyong6@h-partners.com >
2026-08-21 14:59:31 +08:00
xiangcong3
2f3b1ccc0a
卡片问题修复
...
Signed-off-by: xiangcong3 <xiangcong4@huawei.com >
AI[0%] Human Fixed[0%] Human[100%] AI Adopted[0%]
2026-08-20 16:31:50 +08:00
invoker718
f461eff15b
卡片独立包升级适配
...
Signed-off-by: invoker718 <chenhao243@huawei.com >
2025-08-11 21:15:33 +08:00
invoker718
d5b4da0993
拆包应用升级适配
...
Signed-off-by: invoker718 <chenhao243@huawei.com >
2025-08-10 21:42:25 +08:00
invoker718
4b8dc4ccf1
拆包应用升级卡片适配
...
Signed-off-by: invoker718 <chenhao243@huawei.com >
2025-08-03 15:13:03 +08:00
invoker718
f1749dc95c
拆包应用升级卡片适配
...
Signed-off-by: invoker718 <chenhao243@huawei.com >
2025-08-02 21:45:06 +08:00