]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/libs/graph/example/edge-function.cpp
import new upstream nautilus stable release 14.2.8
[ceph.git] / ceph / src / boost / libs / graph / example / edge-function.cpp
index 6ee0b6661cd059830dd4e7acf7dce31a860f0210..ef74062ad93a5cecdd619aeb1952442a0f3321b7 100644 (file)
@@ -73,7 +73,7 @@ name_equals(const std::string & str, NameMap name)
 
 
 int
-main()
+main(int argc, const char** argv)
 {
   typedef adjacency_list<listS,// Store out-edges of each vertex in a std::list
     vecS,                      // Store vertex set in a std::vector
@@ -82,8 +82,8 @@ main()
    >graph_type;
 
   graph_type g;                 // use default constructor to create empty graph
-  const char* dep_file_name = "makefile-dependencies.dat";
-  const char* target_file_name = "makefile-target-names.dat";
+  const char* dep_file_name = argc >= 2 ? argv[1] : "makefile-dependencies.dat";
+  const char* target_file_name = argc >= 3 ? argv[2] : "makefile-target-names.dat";
 
   std::ifstream file_in(dep_file_name), name_in(target_file_name);
   if (!file_in) {