double start, now;
gras_msg_procdata_t pd=
(gras_msg_procdata_t)gras_libdata_by_id(gras_msg_libdata_id);
- int cpt;
+ unsigned int cpt;
xbt_assert0(msg_got,"msg_got is an output parameter");
RETHROW0("Error while waiting for messages: %s");
xbt_ex_free(e);
}
- } while (now - begin < period);
+ /* Epsilon to avoid numerical stability issues were the waited interval is so small that the global clock cannot notice the increment */
+ } while (period - now + begin > 0);
}
/** @brief Handle an incomming message or timer (or wait up to \a timeOut seconds)
double untiltimer;
- int cpt;
+ unsigned int cpt;
int volatile ran_ok;
s_gras_msg_t msg;
"AND IN SIMGRID (process wasn't killed by an assert)",msg.type->name);
if (!ran_ok)
THROW1(mismatch_error,0,
- "Message '%s' refused by all registered callbacks", msg.type->name);
+ "Message '%s' refused by all registered callbacks (maybe your callback misses a 'return 0' at the end)", msg.type->name);
/* FIXME: gras_datadesc_free not implemented => leaking the payload */
break;