]> git.sesse.net Git - vlc/commitdiff
Rationalize error code values
authorRémi Denis-Courmont <remi@remlab.net>
Tue, 4 Dec 2012 21:17:48 +0000 (23:17 +0200)
committerRémi Denis-Courmont <remi@remlab.net>
Tue, 4 Dec 2012 21:17:48 +0000 (23:17 +0200)
VLC_GENERIC was particularly bad for RISC processors.

include/vlc_common.h

index 90d0173be8cb790583c587045f8f0035e5577bad..1ef288cfe001e4c8f3f1b2c896a03b77c2585c80 100644 (file)
@@ -393,20 +393,15 @@ struct vlc_list_t
 /*****************************************************************************
  * Error values (shouldn't be exposed)
  *****************************************************************************/
-#define VLC_SUCCESS         -0                                   /* No error */
-#define VLC_ENOMEM          -1                          /* Not enough memory */
-#define VLC_ETIMEOUT        -3                                    /* Timeout */
-
-#define VLC_ENOMOD         -10                           /* Module not found */
-
-#define VLC_ENOOBJ         -20                           /* Object not found */
-
-#define VLC_ENOVAR         -30                         /* Variable not found */
-#define VLC_EBADVAR        -31                         /* Bad variable value */
-
-#define VLC_ENOITEM        -40                           /**< Item not found */
-
-#define VLC_EGENERIC      -666                              /* Generic error */
+#define VLC_SUCCESS        (-0) /**< No error */
+#define VLC_EGENERIC       (-1) /**< Unspecified error */
+#define VLC_ENOMEM         (-2) /**< Not enough memory */
+#define VLC_ETIMEOUT       (-3) /**< Timeout */
+#define VLC_ENOMOD         (-4) /**< Module not found */
+#define VLC_ENOOBJ         (-5) /**< Object not found */
+#define VLC_ENOVAR         (-6) /**< Variable not found */
+#define VLC_EBADVAR        (-7) /**< Bad variable value */
+#define VLC_ENOITEM        (-8) /**< Item not found */
 
 /*****************************************************************************
  * Variable callbacks