From 3028d14c0b1903582ac16f5eb09e4f33d7b1eb3a Mon Sep 17 00:00:00 2001 From: Marion Guthmuller Date: Thu, 18 Oct 2012 21:37:55 +0200 Subject: [PATCH] model-checker : if get_libsimgrid_plt_section called before first snapshot, libsimgrid_path is NULL --- src/mc/mc_checkpoint.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/mc/mc_checkpoint.c b/src/mc/mc_checkpoint.c index ad1de431dc..b6721f6d2e 100644 --- a/src/mc/mc_checkpoint.c +++ b/src/mc/mc_checkpoint.c @@ -222,7 +222,10 @@ void get_libsimgrid_plt_section(){ int i, plt_not_found = 1; unsigned long int size, offset; - char *command = bprintf( "objdump --section-headers %s", libsimgrid_path); + if(libsimgrid_path == NULL) + libsimgrid_path = get_libsimgrid_path(); + + char *command = bprintf("objdump --section-headers %s", libsimgrid_path); fp = popen(command, "r"); @@ -259,7 +262,6 @@ void get_libsimgrid_plt_section(){ } } - } free(command); -- 2.20.1