mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-01-23 02:14:37 +00:00
crit: do not crash on aarch64 doing 'crit x ./ rss'
Running 'crit x ./ rss' on aarch64 crashes with:
File "/home/criu/crit/crit/__main__.py", line 331, in explore_rss
while vmas[vmi]['start'] < pme:
~~~~^^^^^
IndexError: list index out of range
This adds an additional check to the while loop to do access indexes out
of range.
Signed-off-by: Adrian Reber <areber@redhat.com>
This commit is contained in:
parent
21ea718f9f
commit
615ccf98cf
1 changed files with 2 additions and 2 deletions
|
|
@ -323,12 +323,12 @@ def explore_rss(opts):
|
|||
pvmi = -1
|
||||
for pm in pms[1:]:
|
||||
pstr = '\t%lx / %-8d' % (pm['vaddr'], pm['nr_pages'])
|
||||
while vmas[vmi]['end'] <= pm['vaddr']:
|
||||
while vmi < len(vmas) and vmas[vmi]['end'] <= pm['vaddr']:
|
||||
vmi += 1
|
||||
|
||||
pme = pm['vaddr'] + (pm['nr_pages'] << 12)
|
||||
vstr = ''
|
||||
while vmas[vmi]['start'] < pme:
|
||||
while vmi < len(vmas) and vmas[vmi]['start'] < pme:
|
||||
vma = vmas[vmi]
|
||||
if vmi == pvmi:
|
||||
vstr += ' ~'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue