X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/df1574af1592689f73d940fd6803b55d5eca7156..74486f4fe21d15423003177707cbc7046141c131:/src/amok/Bandwidth/bandwidth.c diff --git a/src/amok/Bandwidth/bandwidth.c b/src/amok/Bandwidth/bandwidth.c index a6fbf24f3f..39bafa4039 100644 --- a/src/amok/Bandwidth/bandwidth.c +++ b/src/amok/Bandwidth/bandwidth.c @@ -129,7 +129,7 @@ void amok_bw_test(gras_socket_t peer, if (port == 10000 -1) { RETHROW0("Error caught while opening a measurement socket: %s"); } else { - xbt_ex_free(e); + xbt_ex_free(&e); } } } @@ -215,7 +215,7 @@ int amok_bw_cb_bw_handshake(gras_msg_cb_ctx_t ctx, } CATCH(e) { measMasterIn = NULL; if (port < 10000) - xbt_ex_free(e); + xbt_ex_free(&e); else /* FIXME: tell error to remote */ RETHROW0("Error encountered while opening a measurement server socket: %s"); @@ -315,8 +315,10 @@ void amok_bw_request(const char* from_name,unsigned int from_port, sock = gras_socket_client(from_name,from_port); gras_msg_rpccall(sock,240,gras_msgtype_by_name("BW request"),&request, &result); - *sec=result->sec; - *bw =result->bw; + if (sec) + *sec=result->sec; + if (bw) + *bw =result->bw; VERB6("BW test between %s:%d and %s:%d took %f sec, achieving %f kb/s", from_name,from_port, to_name,to_port,