{"record":{"id":"44c9b65273b391ea","repo":"Hmbown/CodeWhale","slug":"multiple-proc-self-maps-rows-contain-the-updater","errorCode":null,"errorMessage":"multiple /proc/self/maps rows contain the updater marker","messagePattern":"multiple /proc/self/maps rows contain the updater marker","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/cli/src/update.rs","lineNumber":378,"sourceCode":"            .context(\"loaded-image mapping has an invalid device\")?;\n        let device_major = u32::from_str_radix(device_major, 16)\n            .context(\"loaded-image mapping has an invalid device major number\")?;\n        let device_minor = u32::from_str_radix(device_minor, 16)\n            .context(\"loaded-image mapping has an invalid device minor number\")?;\n        if path.is_empty() {\n            bail!(\"loaded-image mapping for updater marker has no pathname\");\n        }\n\n        let mapping = AndroidImageMapping {\n            start,\n            end,\n            device_major,\n            device_minor,\n            inode,\n            path: PathBuf::from(path),\n        };\n        if matching.replace(mapping).is_some() {\n            bail!(\"multiple /proc/self/maps rows contain the updater marker\");\n        }\n    }\n\n    matching.ok_or_else(|| anyhow!(\"no /proc/self/maps row contains the updater marker\"))\n}\n\n#[cfg(all(test, unix))]\nfn resolve_android_loaded_executable_report(\n    maps: &str,\n    marker: u64,\n    dladdr_path: &Path,\n) -> Result<PathBuf> {\n    Ok(android_loaded_executable_proof_report(maps, marker, dladdr_path)?.path)\n}\n\n#[cfg(any(target_os = \"android\", all(test, unix)))]\nfn android_loaded_executable_proof_report(\n    maps: &str,","sourceCodeStart":360,"sourceCodeEnd":396,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/0c42157ee52f9d55af2b506d71b46249910f77d3/crates/cli/src/update.rs#L360-L396","documentation":"parse_android_image_mapping found two different /proc/self/maps rows whose address ranges both contain the updater marker address. Well-formed maps never have overlapping rows, so this indicates a kernel/loader anomaly or corrupted maps output, and the updater refuses to pick between them.","triggerScenarios":"Android self-update when /proc/self/maps momentarily shows overlapping mappings for the image (races during mapping reorganization) or a kernel/emulator producing malformed maps text.","commonSituations":"Emulators or custom kernels with nonconforming /proc semantics; extremely rare on stock devices.","solutions":["Retry the update after restarting the process","Capture /proc/self/maps from the same session and attach it to a bug report","Fall back to a manual update (download, verify SHA256, replace) while the issue is investigated"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"Catch the error, retry once after a fresh process start (maps are re-read), and if the second attempt fails, escalate to a bug report rather than looping.","preventionTips":["Retry in a new process instance","Collect /proc/selfmaps output at failure time for diagnostics","Avoid kernels/emulators known to emit malformed maps"],"tags":["android","proc-maps","self-update","memory-mappings"],"backgroundTag":"overlapping-memory-mappings","analyzedSha":"0c42157ee52f9d55af2b506d71b46249910f77d3","analyzedAt":"2026-08-20T21:50:45.477Z","schemaVersion":2},"datasetVersion":"2026-08-22T04:17:13.399Z"}