patch-2.0.37 linux/scripts/tkparse.c

Next file: linux/scripts/tkparse.h
Previous file: linux/scripts/tkgen.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.0.36/linux/scripts/tkparse.c linux/scripts/tkparse.c
@@ -345,6 +345,11 @@
       tok = tok_define;
       pnt += 11;
     }
+  else if (strncmp(pnt, "define_int", 10) == 0) 
+    {
+      tok = tok_define_int;
+      pnt += 10;
+    }
   else if (strncmp(pnt, "bool", 4) == 0) 
     {
       tok = tok_bool;
@@ -446,6 +451,10 @@
       if(*pnt == 'y' || *pnt == 'Y' ) kcfg->value = "1";
       if(*pnt == 'n' || *pnt == 'N' ) kcfg->value = "0";
       if(*pnt == 'm' || *pnt == 'M' ) kcfg->value = "2";
+      break;
+    case tok_define_int:
+      pnt = get_string(pnt, &kcfg->optionname);
+      pnt = get_string(pnt, &kcfg->value);
       break;
     case tok_menuname:
       pnt = get_qstring(pnt, &kcfg->label);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov