X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/d22c100149c15b1423e8235fca44e80e4321e558..a0b9c1cc62e78a0be8dd6f117816d19356e2e0ce:/src/gras/Msg/rpc.c diff --git a/src/gras/Msg/rpc.c b/src/gras/Msg/rpc.c index bd93d54621..85d30d2b02 100644 --- a/src/gras/Msg/rpc.c +++ b/src/gras/Msg/rpc.c @@ -110,12 +110,11 @@ void gras_msg_rpc_async_wait(gras_msg_cb_ctx_t ctx, &received); free(ctx); if (received.kind == e_gras_msg_kind_rpcerror) { - /* Damn. Got an exception. Extract it and revive it */ xbt_ex_t e; memcpy(&e,received.payl,received.payl_size); - VERB2("Raise a remote exception comming from %s %s",e.host, - (__xbt_ex_ctx()->ctx_caught?"caught":"not caught")); free(received.payl); + VERB3("Raise a remote exception cat:%d comming from %s (%s)", + e.category, e.host, e.msg); __xbt_ex_ctx()->ctx_ex.msg = e.msg; __xbt_ex_ctx()->ctx_ex.category = e.category; __xbt_ex_ctx()->ctx_ex.value = e.value; @@ -126,9 +125,10 @@ void gras_msg_rpc_async_wait(gras_msg_cb_ctx_t ctx, __xbt_ex_ctx()->ctx_ex.line = e.line; __xbt_ex_ctx()->ctx_ex.func = e.func; __xbt_ex_ctx()->ctx_ex.used = e.used; - // memcpy((void*)&(__xbt_ex_ctx()->ctx_ex),&e,sizeof(xbt_ex_t)); + __xbt_ex_ctx()->ctx_ex.bt_strings = e.bt_strings; + memset(&__xbt_ex_ctx()->ctx_ex.bt,0, + sizeof(__xbt_ex_ctx()->ctx_ex.bt)); DO_THROW(__xbt_ex_ctx()->ctx_ex); - } memcpy(answer,received.payl,received.payl_size); free(received.payl); @@ -154,6 +154,7 @@ void gras_msg_rpccall(gras_socket_t server, */ void gras_msg_rpcreturn(double timeOut,gras_msg_cb_ctx_t ctx,void *answer) { - gras_msg_send_ext(ctx->expeditor, e_gras_msg_kind_rpcanswer, ctx->ID, ctx->msgtype, answer); + gras_msg_send_ext(ctx->expeditor, e_gras_msg_kind_rpcanswer, + ctx->ID, ctx->msgtype, answer); }