OSSP CVS Repository

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

Check-in Number: 3474
Date: 2003-Jun-30 17:09:46 (local)
2003-Jun-30 15:09:46 (UTC)
User:ms
Branch:
Comment: Fix some verbose mode print run definitions, and fix error handling by using correct value 0 for RC_OK.
Tickets:
Inspections:
Files:
ossp-pkg/rc/rc.h      1.53 -> 1.54     15 inserted, 15 deleted
ossp-pkg/rc/rc_proc.c      1.51 -> 1.52     3 inserted, 3 deleted

ossp-pkg/rc/rc.h 1.53 -> 1.54

--- rc.h 2003/06/30 14:43:36     1.53
+++ rc.h 2003/06/30 15:09:46     1.54
@@ -52,21 +52,21 @@
 
 /* Rc return codes */
 typedef enum {
-    RC_OK      = 1,  /* Success                  */
-    RC_ERR_0   = 2,  /* Error base               */
-    RC_ERR_USE = 3,  /* Usage error              */
-    RC_ERR_MEM = 4,  /* Memory error             */
-    RC_ERR_SYS = 5,  /* System error (see errno) */
-    RC_ERR_IO  = 6,  /* Input/output error       */
-    RC_ERR_INT = 7,  /* Internal error           */
-    RC_ERR_FNC = 8,  /* Func file not found      */
-    RC_ERR_DIR = 9,  /* Location dir not found   */
-    RC_ERR_RCF = 10, /* Rc file not found        */
-    RC_ERR_TRM = 11, /* Request to terminate app */
-    RC_ERR_CFG = 12, /* Config or option failure */
-    RC_WRN_0   = 13, /* Warning base             */
-    RC_WRN_OWR = 14, /* Overwrite warning        */
-    RC_WRN_NUL = 15  /* NULL pointer warning     */
+    RC_OK      = 0,  /* Success                  */
+    RC_ERR_0   = 1,  /* Error base               */
+    RC_ERR_USE = 2,  /* Usage error              */
+    RC_ERR_MEM = 3,  /* Memory error             */
+    RC_ERR_SYS = 4,  /* System error (see errno) */
+    RC_ERR_IO  = 5,  /* Input/output error       */
+    RC_ERR_INT = 6,  /* Internal error           */
+    RC_ERR_FNC = 7,  /* Func file not found      */
+    RC_ERR_DIR = 8,  /* Location dir not found   */
+    RC_ERR_RCF = 9,  /* Rc file not found        */
+    RC_ERR_TRM = 10, /* Request to terminate app */
+    RC_ERR_CFG = 11, /* Config or option failure */
+    RC_WRN_0   = 12, /* Warning base             */
+    RC_WRN_OWR = 13, /* Overwrite warning        */
+    RC_WRN_NUL = 14  /* NULL pointer warning     */
 } rc_return_t;
 
 /* Config function prototypes */


ossp-pkg/rc/rc_proc.c 1.51 -> 1.52

--- rc_proc.c    2003/06/30 14:43:36     1.51
+++ rc_proc.c    2003/06/30 15:09:46     1.52
@@ -473,13 +473,13 @@
             fprintf(stderr, "%s\n", RC_VST_TEXT);
         /* Conditionally print funcs section notice in verbal mode */
         if (configGetval(RC_VRB_VAL))
-            fprintf(stderr, "%s\n", RC_EVF_TEXT);
+            fprintf(stderr, "%s\n", RC_PNF_TEXT);
         scriptDump(pRc->m_pScriptfunc); /* Dump the funcs script */
         /* Conditionally print config section notice in verbal mode */
         if (configGetval(RC_VRB_VAL)) {
-            nBytes = (strlen(RC_EVN_TEXT) + strlen(RC_DEF_NCF) * 2 + 2) * sizeof (char);
+            nBytes = (strlen(RC_PRN_TEXT) + strlen(RC_DEF_NCF) * 2 + 2) * sizeof (char);
             szVerbose = malloc(nBytes);
-            sprintf(szVerbose, RC_EVN_TEXT, RC_DEF_NCF, RC_DEF_NCF);
+            sprintf(szVerbose, RC_PRN_TEXT, RC_DEF_NCF, RC_DEF_NCF);
             strcat(szVerbose, "\n");
             fprintf(stderr, szVerbose);
             free(szVerbose);

CVSTrac 2.0.1