OSSP CVS Repository

ossp - Difference in ossp-pkg/rc/rc_error.c versions 1.3 and 1.4
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/rc/rc_error.c 1.3 -> 1.4

--- rc_error.c   2003/06/24 09:35:39     1.3
+++ rc_error.c   2003/06/30 15:27:38     1.4
@@ -67,9 +67,12 @@
         else if ((rc_return_t)Localerr.ex_value == RC_ERR_CFG)
             fprintf(stderr, "    Error condition, configuration and options failure in %s:%s():%d.\n", \
                 Localerr.ex_file, Localerr.ex_func, Localerr.ex_line);
+        else if ((rc_return_t)Localerr.ex_value == RC_ERR_ROOT)
+            fprintf(stderr, "    Error condition, in %s:%s():%d. You must be root to run these commands\n", \
+                Localerr.ex_file, Localerr.ex_func, Localerr.ex_line);
         else
             fprintf(stderr, "    Error condition of class '%s',\n    exception %d in %s:%s():%d.\n", (char *)Localerr.ex_class, (int)Localerr.ex_value, Localerr.ex_file, Localerr.ex_func, Localerr.ex_line);
-        exit(1); /* Return failure */
+        exit((int)Localerr.ex_value); /* Return failure */
     }
 #ifdef DEBUG
     else        /* Warning condition */

CVSTrac 2.0.1