(url: str, dest: Path)
| 38 | |
| 39 | |
| 40 | def download_elf(url: str, dest: Path) -> None: |
| 41 | with urllib.request.urlopen(url) as resp: |
| 42 | if resp.status >= 400: |
| 43 | raise RuntimeError(f"Failed to download ELF: HTTP {resp.status}") |
| 44 | data = resp.read() |
| 45 | dest.write_bytes(data) |
| 46 | |
| 47 | |
| 48 | def decode_addresses(elf_path: Path, addresses: list) -> dict: |