OSSP CVS Repository

ossp - Check-in [2836]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2836
Date: 2002-Nov-18 11:25:41 (local)
2002-Nov-18 10:25:41 (UTC)
User:rse
Branch:
Comment: better reporting
Tickets:
Inspections:
Files:
ossp-pkg/cfg/cfg_test.c      1.11 -> 1.12     5 inserted, 2 deleted

ossp-pkg/cfg/cfg_test.c 1.11 -> 1.12

--- cfg_test.c   2002/11/18 10:23:36     1.11
+++ cfg_test.c   2002/11/18 10:25:41     1.12
@@ -56,14 +56,16 @@
     free(ex_ptr);
 
     if (argc == 3) {
+        fprintf(stdout, "==== selection process ====\n");
         if ((rc = cfg_node_select(cfg, NULL, &vec, "%s", argv[2])) != CFG_OK) {
             cfg_error(cfg, rc, &error);
             fprintf(stderr, "ERROR: cfg_node_select: %s\n", error);
             cfg_destroy(cfg);
             exit(1);
         }
-        for (i = 1; vec[i] != NULL; i++) {
-            fprintf(stdout, "---- selection #%d ----\n", i);
+        fprintf(stdout, "==== selection results ====\n");
+        for (i = 0; vec[i] != NULL; i++) {
+            fprintf(stdout, "---- selection result #%d ----\n", i);
             if ((rc = cfg_export(cfg, vec[i], CFG_FMT_CFG, &ex_ptr, 0)) != CFG_OK) {
                 cfg_error(cfg, rc, &error);
                 fprintf(stderr, "ERROR: cfg_export: %s\n", error);
@@ -74,6 +76,7 @@
             fprintf(stdout, "---- selection #%d ----\n", i);
             free(ex_ptr);
         }
+        fprintf(stdout, "==== selection end ====\n");
     }
 
     cfg_destroy(cfg);

CVSTrac 2.0.1