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
Correclty handle the case p1 < p2 in cmpstringp.
[simgrid.git]
/
tools
/
tesh
/
run_context.c
diff --git
a/tools/tesh/run_context.c
b/tools/tesh/run_context.c
index
fcf6d3c
..
1eaaedf
100644
(file)
--- a/
tools/tesh/run_context.c
+++ b/
tools/tesh/run_context.c
@@
-653,7
+653,7
@@
static int cmpstringp(const void *p1, const void *p2) {
int res = strncmp(s1, s2, sort_len);
if (res == 0)
- re
turn p1>p2
;
+ re
s = p1 > p2 ? 1 : (p1 < p2 ? -1 : 0)
;
return res;
}