ConfigFile by shintamainjp with MAXLEN_VALUE extended to 500 characters

Fork of ConfigFile by Shinichiro Nakamura

Revision:
7:6ae4c48cc8c1
Parent:
6:f6ceafabe9f8
--- a/ConfigFile.cpp	Wed Sep 15 13:49:15 2010 +0000
+++ b/ConfigFile.cpp	Wed Dec 10 20:24:28 2014 +0000
@@ -300,11 +300,14 @@
      * Read from a file.
      */
     char buf[MAXLEN_KEY + 8 + MAXLEN_VALUE];
+    //printf("CFG: Reading in lines...\r\n");
     while (fgets(buf, sizeof(buf), fp) != NULL) {
+        //printf("CFG: Line: %s", buf);
         /*
          * Ignore a comment.
          */
         if (buf[0] == '#') {
+            //printf("CFG: Comment\r\n");
             continue;
         }
 
@@ -326,8 +329,10 @@
         char *sp = strchr(buf, SEPARATOR);
         if (sp != NULL) {
             strcpy(v, sp + 1);
+            //printf("CFG: Value: %s\r\n", v);
             *sp = '\0';
             strcpy(k, buf);
+            //printf("CFG: Key: %s\r\n", k);
             setValue(k, v);
         }
     }