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
play with mpich3 cmake files
[simgrid.git]
/
src
/
simdag
/
sd_dotloader.cpp
diff --git
a/src/simdag/sd_dotloader.cpp
b/src/simdag/sd_dotloader.cpp
index
d33cb25
..
423df63
100644
(file)
--- a/
src/simdag/sd_dotloader.cpp
+++ b/
src/simdag/sd_dotloader.cpp
@@
-4,6
+4,7
@@
/* 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 "src/internal_config.h"
#include "src/simdag/simdag_private.h"
#include "simgrid/simdag.h"
#include "xbt/file.h"
#include "src/simdag/simdag_private.h"
#include "simgrid/simdag.h"
#include "xbt/file.h"
@@
-11,13
+12,8
@@
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(sd_dotparse, sd, "Parsing DOT files");
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(sd_dotparse, sd, "Parsing DOT files");
-#if
def HAVE_CGRAPH_H
+#if
HAVE_GRAPHVIZ
#include <graphviz/cgraph.h>
#include <graphviz/cgraph.h>
-#elif HAVE_AGRAPH_H
-#include <graphviz/agraph.h>
-#define agnxtnode(dot, node) agnxtnode(node)
-#define agfstout(dot, node) agfstout(node)
-#define agnxtout(dot, edge) agnxtout(edge)
#endif
typedef enum {
#endif
typedef enum {
@@
-244,7
+240,9
@@
xbt_dynar_t SD_dotload_generic(const char * filename, seq_par_t seq_or_par, bool
}
if (result && !acyclic_graph_detail(result)) {
}
if (result && !acyclic_graph_detail(result)) {
- XBT_ERROR("The DOT described in %s is not a DAG. It contains a cycle.", xbt_basename((char*)filename));
+ char* base = xbt_basename(filename);
+ XBT_ERROR("The DOT described in %s is not a DAG. It contains a cycle.", base);
+ free(base);
xbt_dynar_free(&result);
result = NULL;
}
xbt_dynar_free(&result);
result = NULL;
}