diff options
Diffstat (limited to 'tools/libxc/xc_core.c')
-rw-r--r-- | tools/libxc/xc_core.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/libxc/xc_core.c b/tools/libxc/xc_core.c index a7fd1647f3..ef1e8dd7a1 100644 --- a/tools/libxc/xc_core.c +++ b/tools/libxc/xc_core.c @@ -518,7 +518,17 @@ xc_domain_dumpcore_via_callback(int xc_handle, if ( sts != 0 ) goto out; + /* + * Note: this is the *current* number of pages and may change under + * a live dump-core. We'll just take this value, and if more pages + * exist, we'll skip them. If there's less, then we'll just not use + * all the array... + * + * We don't want to use the total potential size of the memory map + * since that is usually much higher than info.nr_pages. + */ nr_pages = info.nr_pages; + if ( !auto_translated_physmap ) { /* obtain p2m table */ |