A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
use assignment to non-trivial class rather than artificial trivialization and memset
[simgrid.git]
/
teshsuite
/
mc
/
random-bug
/
random-bug.cpp
diff --git
a/teshsuite/mc/random-bug/random-bug.cpp
b/teshsuite/mc/random-bug/random-bug.cpp
index
6f8463d
..
03bc2ae
100644
(file)
--- a/
teshsuite/mc/random-bug/random-bug.cpp
+++ b/
teshsuite/mc/random-bug/random-bug.cpp
@@
-12,7
+12,7
@@
XBT_LOG_NEW_DEFAULT_CATEGORY(random_bug, "For this example");
enum { ABORT, ASSERT, PRINTF } behavior;
enum { ABORT, ASSERT, PRINTF } behavior;
-/** A
n (fake)
application with a bug occuring for some random values */
+/** A
fake
application with a bug occuring for some random values */
static void app()
{
int x = MC_random(0, 5);
static void app()
{
int x = MC_random(0, 5);
@@
-42,6
+42,9
@@
int main(int argc, char* argv[])
} else if (strcmp(argv[1], "printf") == 0) {
XBT_INFO("Behavior: printf");
behavior = PRINTF;
} else if (strcmp(argv[1], "printf") == 0) {
XBT_INFO("Behavior: printf");
behavior = PRINTF;
+ } else {
+ xbt_die("Please use either 'abort', 'assert' or 'printf' as first parameter, to specify what to do when the error "
+ "is found.");
}
e.load_platform(argv[2]);
}
e.load_platform(argv[2]);