Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
debug logs tweaking; to reset the exception container correctly
authormquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 11 Apr 2006 12:03:40 +0000 (12:03 +0000)
committermquinson <mquinson@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 11 Apr 2006 12:03:40 +0000 (12:03 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@2118 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/gras/Msg/rpc.c

index 551ab75..85d30d2 100644 (file)
@@ -110,13 +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);
     free(received.payl);
-    VERB3("Raise a remote exception cat:%d comming from %s %s",
-         e.category, e.host,
-         (__xbt_ex_ctx()->ctx_caught?"caught":"not caught"));
+    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;
@@ -128,6 +126,8 @@ void gras_msg_rpc_async_wait(gras_msg_cb_ctx_t ctx,
      __xbt_ex_ctx()->ctx_ex.func     = e.func;
      __xbt_ex_ctx()->ctx_ex.used     = e.used;
      __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);