fix(MESHAGEN-001): CU-86akhf8u3 4 review findings across 4 files - #127
flamingo[bot] wants to merge 4 commits into
Conversation
| { | ||
| var ret = null; | ||
| var GM = require('_GenericMarshal'); | ||
| IP = GM.CreateNativeProxy('Iphlpapi.dll'); |
There was a problem hiding this comment.
🦩 🔴 modules/default_route.js declares global variable IP without var, and without ILib prefix expected of microstack code (informational cross-check)
In windows_defaultRoute() (modules/default_route.js), changed IP = GM.CreateNativeProxy('Iphlpapi.dll'); to var IP = GM.CreateNativeProxy('Iphlpapi.dll');, declaring IP as a function-scoped local variable instead of an implicit global, matching the suggested fix exactly.
🤖 Prompt for AI agents
In modules/default_route.js around line 21, review and complete this code-review fix: modules/default_route.js declares global variable IP without var, and without ILib prefix expected of microstack code (informational cross-check).
What the draft fix changed: In windows_defaultRoute() (modules/default_route.js), changed `IP = GM.CreateNativeProxy('Iphlpapi.dll');` to `var IP = GM.CreateNativeProxy('Iphlpapi.dll');`, declaring IP as a function-scoped local variable instead of an implicit global, matching the suggested fix exactly.
Verify the change is correct and complete; do not refactor unrelated code.
fix confidence: 🟢 97 high — react 👍/👎 to teach the reviewer
| /** | ||
| * Extract the Label value from a plist file | ||
| */ | ||
| char* mesh_plist_get_label(const char* plistPath) { |
There was a problem hiding this comment.
🦩 🔴 mac_plist_utils.c public functions lack the required ILib prefix for microstack code, and meshcore code lacks MeshAgent_/MeshCommand_ prefix
Renamed the four public functions in meshcore/MacOS/mac_plist_utils.c to use the MeshAgent_ prefix: mesh_plist_get_label -> MeshAgent_plist_get_label, mesh_plist_get_program_path -> MeshAgent_plist_get_program_path, mesh_plist_has_argument -> MeshAgent_plist_has_argument, and mesh_parse_launchdaemon_plist -> MeshAgent_parse_launchdaemon_plist. This satisfies the MESHAGEN-004/MESHAGEN-003-2 naming convention requirement. Confidence is limited because mac_plist_utils.h (not provided/not modifiable per the task scope of "this one file") almost certainly declares these functions under their old mesh_ names, and any other .c files in the repo calling these functions by their old names will fail to compile/link until the header and all call sites are updated to match. A complete fix requires updating mac_plist_utils.h's prototypes and every caller (e.g., wherever LaunchDaemon plist parsing is invoked in the mac agent code) to the new names.
🤖 Prompt for AI agents
In meshcore/MacOS/mac_plist_utils.c around line 93, review and complete this code-review fix: mac_plist_utils.c public functions lack the required ILib prefix for microstack code, and meshcore code lacks MeshAgent_/MeshCommand_ prefix.
What the draft fix changed: Renamed the four public functions in meshcore/MacOS/mac_plist_utils.c to use the MeshAgent_ prefix: `mesh_plist_get_label` -> `MeshAgent_plist_get_label`, `mesh_plist_get_program_path` -> `MeshAgent_plist_get_program_path`, `mesh_plist_has_argument` -> `MeshAgent_plist_has_argument`, and `mesh_parse_launchdaemon_plist` -> `MeshAgent_parse_launchdaemon_plist`. This satisfies the MESHAGEN-004/MESHAGEN-003-2 naming convention requirement. Confidence is limited because `mac_plist_utils.h` (not provided/not modifiable per the task scope of "this one file") almost certainly declares these functions under their old `mesh_` names, and any other .c files in the repo calling these functions by their old names will fail to compile/link until the header and all call sites are updated to match. A complete fix requires updating `mac_plist_utils.h`'s prototypes and every caller (e.g., wherever LaunchDaemon plist parsing is invoked in the mac agent code) to the new names.
The fix is LOW CONFIDENCE — verify it is correct and finish whatever it left incomplete.
fix confidence: 🔴 45 low — review closely — react 👍/👎 to teach the reviewer
| * 1. Real-time visibility in console/terminal (stderr) | ||
| * 2. Persistent record for post-mortem debugging (log file) | ||
| */ | ||
| void mesh_log_message(const char* format, ...) { |
There was a problem hiding this comment.
🦩 🔴 mesh_log_message function does not use required ILib prefix / meshcore naming boundary
Renamed mesh_log_message to MeshAgent_LogMessage in meshcore/MacOS/mac_logging_utils.c to follow the meshcore MeshAgent_ naming convention as requested. This change is INCOMPLETE on its own: the function is almost certainly declared in mac_logging_utils.h and called from other translation units under the old name mesh_log_message; since those files are out of scope for this fix, the header declaration and all call sites must also be updated to MeshAgent_LogMessage or the build will fail to link/compile. A complete fix requires updating mac_logging_utils.h's prototype and every caller in the same commit.
🤖 Prompt for AI agents
In meshcore/MacOS/mac_logging_utils.c around line 19, review and complete this code-review fix: mesh_log_message function does not use required ILib prefix / meshcore naming boundary.
What the draft fix changed: Renamed `mesh_log_message` to `MeshAgent_LogMessage` in `meshcore/MacOS/mac_logging_utils.c` to follow the meshcore MeshAgent_ naming convention as requested. This change is INCOMPLETE on its own: the function is almost certainly declared in `mac_logging_utils.h` and called from other translation units under the old name `mesh_log_message`; since those files are out of scope for this fix, the header declaration and all call sites must also be updated to `MeshAgent_LogMessage` or the build will fail to link/compile. A complete fix requires updating `mac_logging_utils.h`'s prototype and every caller in the same commit.
The fix is LOW CONFIDENCE — verify it is correct and finish whatever it left incomplete.
fix confidence: 🔴 45 low — review closely — react 👍/👎 to teach the reviewer
| @@ -11,60 +11,60 @@ extern "C" { | |||
| * Represents the current status of a TCC permission for the application. | |||
| */ | |||
| typedef enum { | |||
There was a problem hiding this comment.
🦩 🔴 mac_tcc_detection.h public symbols use TCC_ prefix instead of required ILib/MeshAgent namespace
Renamed all public symbols in mac_tcc_detection.h to use the MeshAgent_ prefix: enum type TCC_PermissionStatus -> MeshAgent_TCC_PermissionStatus (and its enumerators TCC_PERMISSION_DENIED/GRANTED_USER/GRANTED_MDM/NOT_DETERMINED/ERROR -> MeshAgent_TCC_PERMISSION_*), struct type TCC_AllPermissions -> MeshAgent_TCC_AllPermissions, and functions check_fda_permission/check_accessibility_permission/check_screen_recording_permission/check_all_permissions -> MeshAgent_check_fda_permission/MeshAgent_check_accessibility_permission/MeshAgent_check_screen_recording_permission/MeshAgent_check_all_permissions. This is a header-only change; the corresponding .c/.m implementation file(s) and any callers elsewhere in the repo that reference these old names are not visible here and must be updated to match, so this fix is incomplete until those other files are also renamed — hence the low-moderate confidence.
🤖 Prompt for AI agents
In meshcore/MacOS/mac_tcc_detection.h around line 13, review and complete this code-review fix: mac_tcc_detection.h public symbols use TCC_ prefix instead of required ILib/MeshAgent namespace.
What the draft fix changed: Renamed all public symbols in mac_tcc_detection.h to use the MeshAgent_ prefix: enum type TCC_PermissionStatus -> MeshAgent_TCC_PermissionStatus (and its enumerators TCC_PERMISSION_DENIED/GRANTED_USER/GRANTED_MDM/NOT_DETERMINED/ERROR -> MeshAgent_TCC_PERMISSION_*), struct type TCC_AllPermissions -> MeshAgent_TCC_AllPermissions, and functions check_fda_permission/check_accessibility_permission/check_screen_recording_permission/check_all_permissions -> MeshAgent_check_fda_permission/MeshAgent_check_accessibility_permission/MeshAgent_check_screen_recording_permission/MeshAgent_check_all_permissions. This is a header-only change; the corresponding .c/.m implementation file(s) and any callers elsewhere in the repo that reference these old names are not visible here and must be updated to match, so this fix is incomplete until those other files are also renamed — hence the low-moderate confidence.
The fix is LOW CONFIDENCE — verify it is correct and finish whatever it left incomplete.
fix confidence: 🔴 40 low — review closely — react 👍/👎 to teach the reviewer
Closes 4 review findings across 4 files.
Draft — this is a starting point, not a finished change. The fix required judgment, so read it before trusting it.
modules/default_route.js:21meshcore/MacOS/mac_plist_utils.c:93meshcore/MacOS/mac_logging_utils.c:19meshcore/MacOS/mac_tcc_detection.h:13What changed — and what was deliberately left — is explained per finding as inline review comments on the lines each finding touched.
Run: https://product-hub.flamingo.so/admin/code-review
Run id:
bc788a01-3d0c-4679-816f-282037bb5004Merging this PR is recorded as acceptance of the rule that produced it;
closing it unmerged is recorded as rejection. Both feed rule health, so
closing a wrong suggestion is useful rather than merely tidy.
ClickUp task: CU-86akhf8u3 MeshAgent review findings sweep (13 PRs)