OSSP CVS Repository

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

Check-in Number: 3395
Date: 2003-May-28 15:31:55 (local)
2003-May-28 13:31:55 (UTC)
User:ms
Branch:
Comment: Bug fix section to script extractor, and remove unneeded white space stripper.
Tickets:
Inspections:
Files:
ossp-pkg/rc/rc_script.c      1.26 -> 1.27     3 inserted, 5 deleted
ossp-pkg/rc/rc_test/rc.ntp      1.5 -> 1.6     0 inserted, 1 deleted

ossp-pkg/rc/rc_script.c 1.26 -> 1.27

--- rc_script.c  2003/05/27 15:09:09     1.26
+++ rc_script.c  2003/05/28 13:31:55     1.27
@@ -215,11 +215,10 @@
             strncpy(szTemp, piStart, piEnd - piStart + 1);
             piSubtemp = strstr(szTemp, RC_DEF_PRG);
             if (piSubtemp) { /* Priority pattern found */
-                for (nTmp = (int)piSubtemp + strlen(RC_DEF_PRG);\
-                    isspace(nTmp); nTmp += sizeof (char)); /* Strip */
+                nTmp = (int)piSubtemp + strlen(RC_DEF_PRG);
                 nPri = strtol((char *)nTmp, &piSep, 10);
                 if ((char *)nTmp == piSep)  /* No priority number follows */
-                    sectionSetpri(pSec, RC_DEF_PRI); /* which is an error */
+                    RC_THROW(RC_ERR_USE);   /* which is an error */
                 else
                     sectionSetpri(pSec, nPri);  /* Found a priority value */
             }
@@ -229,8 +228,7 @@
             /* Handle the section userid   */
             piSubtemp = strstr(szTemp, RC_DEF_UIG);
             if (piSubtemp) { /* Userid pattern found */
-                for (nTmp = (int)piSubtemp + strlen(RC_DEF_UIG); \
-                    isspace(nTmp); nTmp += sizeof (char)); /* Strip */
+                nTmp = (int)piSubtemp + strlen(RC_DEF_UIG);
                 nUid = strtol((char *)nTmp, &piSep, 10);
                 if ((char *)nTmp == piSep)      /* No userid number follows */
                 {


ossp-pkg/rc/rc_test/rc.ntp 1.5 -> 1.6

--- rc.ntp       2003/05/22 14:45:15     1.5
+++ rc.ntp       2003/05/28 13:31:56     1.6
@@ -16,7 +16,6 @@
     cat $0
 
 %stop -p 200 -u root
-    opServiceEnabled ntp || exit 0
     kill -TERM `cat /sw/var/ntp/ntp.pid`
 
 echo "Run commands NTP finishing"

CVSTrac 2.0.1