From df837e0ddb2a1a65e0f8c8317c890df416d1c4c3 Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Thu, 5 Jan 2012 16:51:34 +0100 Subject: [PATCH] Fix test, and remove duplicated checks. --- src/mc/mc_request.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/mc/mc_request.c b/src/mc/mc_request.c index f2956a4d92..a05c58749d 100644 --- a/src/mc/mc_request.c +++ b/src/mc/mc_request.c @@ -205,7 +205,7 @@ char *MC_request_to_string(smx_req_t req, int value) break; case REQ_COMM_TEST: act = req->comm_test.comm; - if(act->comm.src_proc == NULL || act->comm.src_proc == NULL){ + if(act->comm.src_proc == NULL || act->comm.dst_proc == NULL){ type = xbt_strdup("Test FALSE"); p = pointer_to_string(act); args = bprintf("comm=%s", p); @@ -213,10 +213,8 @@ char *MC_request_to_string(smx_req_t req, int value) type = xbt_strdup("Test TRUE"); p = pointer_to_string(act); args = bprintf("comm=%s [(%lu)%s -> (%lu)%s]", p, - act->comm.src_proc ? act->comm.src_proc->pid : 0, - act->comm.src_proc ? act->comm.src_proc->name : "", - act->comm.dst_proc ? act->comm.dst_proc->pid : 0, - act->comm.dst_proc ? act->comm.dst_proc->name : ""); + act->comm.src_proc->pid, act->comm.src_proc->name, + act->comm.dst_proc->pid, act->comm.dst_proc->name); } break; -- 2.20.1