mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-01-23 02:14:37 +00:00
coredump: use compat_nr_pages as fallback
Use nr_pages when available, falling back to compat_nr_pages for compatibility. Signed-off-by: alam0rt <sam@samlockart.com> Signed-off-by: Radostin Stoyanov <rstoyanov@fedoraproject.org>
This commit is contained in:
parent
0fa6ff3d18
commit
cb8e1da3f4
1 changed files with 2 additions and 1 deletions
|
|
@ -794,7 +794,8 @@ class coredump_generator:
|
|||
off = 0 # in pages
|
||||
for m in pagemap[1:]:
|
||||
found = False
|
||||
for i in range(m["nr_pages"]):
|
||||
num_pages = m.get("nr_pages", m.compat_nr_pages)
|
||||
for i in range(num_pages):
|
||||
if m["vaddr"] + i * PAGESIZE == page_no * PAGESIZE:
|
||||
found = True
|
||||
break
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue