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
sonar: disable a weird rule
[simgrid.git]
/
teshsuite
/
simix
/
stack-overflow
/
stack-overflow.cpp
diff --git
a/teshsuite/simix/stack-overflow/stack-overflow.cpp
b/teshsuite/simix/stack-overflow/stack-overflow.cpp
index 8c56b32b66024ae3c1467ddb48267b1fa14fc878..d6c044f1cc2bb94e9e44efcafb14b1731dddfd5d 100644
(file)
--- a/
teshsuite/simix/stack-overflow/stack-overflow.cpp
+++ b/
teshsuite/simix/stack-overflow/stack-overflow.cpp
@@
-1,11
+1,11
@@
/* stack_overflow -- simple program generating a stack overflow */
/* stack_overflow -- simple program generating a stack overflow */
-/* Copyright (c) 2014-201
8
. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2014-201
9
. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
-#include "simgrid/simix.h"
+#include "simgrid/simix.h
pp
"
#include "xbt/log.h"
#include <simgrid/engine.h>
#include "xbt/log.h"
#include <simgrid/engine.h>
@@
-28,7
+28,7
@@
static unsigned collatz(unsigned c0, unsigned n)
return x;
}
return x;
}
-static
int master(int argc, char* argv[]
)
+static
void master(
)
{
XBT_INFO("Launching our nice bugged recursive function...");
unsigned i = 1;
{
XBT_INFO("Launching our nice bugged recursive function...");
unsigned i = 1;
@@
-37,7
+37,6
@@
static int master(int argc, char* argv[])
unsigned res = collatz(i, i);
XBT_VERB("collatz(%u, %u) returned %u", i, i, res);
}
unsigned res = collatz(i, i);
XBT_VERB("collatz(%u, %u) returned %u", i, i, res);
}
- return 0;
}
int main(int argc, char* argv[])
}
int main(int argc, char* argv[])
@@
-46,9
+45,8
@@
int main(int argc, char* argv[])
xbt_assert(argc == 2, "Usage: %s platform.xml\n", argv[0]);
xbt_assert(argc == 2, "Usage: %s platform.xml\n", argv[0]);
- simgrid_register_function("master", master);
simgrid_load_platform(argv[1]);
simgrid_load_platform(argv[1]);
- simcall_process_create("master", master, NULL, sg_host_by_name("Tremblay"),
0, NULL,
NULL);
+ simcall_process_create("master", master, NULL, sg_host_by_name("Tremblay"), NULL);
SIMIX_run();
return 0;
SIMIX_run();
return 0;