Commit 9a33442
Handle empty file size loadable segments
In cases such as those if the application has no .data but has .bss,
the .bss may end up being alone in an empty filesz loadable segment.
Handle such situation by only `mmap`ing file contents if the segment
has actual file contents (filesz != 0).
Signed-off-by: Sergiu Moga <[email protected]>
Approved-by: Razvan Deaconescu <[email protected]>
Reviewed-by: Razvan Deaconescu <[email protected]>
GitHub-Closes: #851 parent 8b55bff commit 9a33442
1 file changed
+18
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
519 | 519 | | |
520 | 520 | | |
521 | 521 | | |
522 | | - | |
523 | | - | |
524 | | - | |
525 | | - | |
526 | | - | |
527 | | - | |
528 | | - | |
529 | | - | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
530 | 540 | | |
531 | 541 | | |
532 | 542 | | |
533 | | - | |
534 | | - | |
535 | 543 | | |
536 | 544 | | |
537 | 545 | | |
| |||
0 commit comments