[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] xenpm: Initialize cputopo pointer
commit b315cd9cce5b6da7ca89b2d7bad3fb01e7716044 Author: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> AuthorDate: Wed May 13 13:37:35 2015 -0400 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Thu May 14 09:58:43 2015 +0100 xenpm: Initialize cputopo pointer Commit 250f0b43af1a ("libxl/libxc: Move libxl_get_cpu_topology()'s hypercall buffer management to libxc") broke non-debug compilation: on error path we may have uninitialized cputopo pointer. Signed-off-by: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> Reported-by: Olaf Hering <olaf@xxxxxxxxx> Acked-by: Wei Liu <wei.liu2@xxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- tools/misc/xenpm.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/misc/xenpm.c b/tools/misc/xenpm.c index 24ee6ef..fe2c001 100644 --- a/tools/misc/xenpm.c +++ b/tools/misc/xenpm.c @@ -355,7 +355,7 @@ static void signal_int_handler(int signo) int i, j, k; struct timeval tv; int cx_cap = 0, px_cap = 0; - xc_cputopo_t *cputopo; + xc_cputopo_t *cputopo = NULL; unsigned max_cpus; if ( xc_cputopoinfo(xc_handle, &max_cpus, NULL) != 0 ) @@ -960,7 +960,7 @@ void scaling_governor_func(int argc, char *argv[]) void cpu_topology_func(int argc, char *argv[]) { - xc_cputopo_t *cputopo; + xc_cputopo_t *cputopo = NULL; unsigned max_cpus; int i, rc; -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |