Commit f1796d59 f1796d5998e65b13c6ba058a805618c7e7fa270e by uid65697

New error codes

1 parent f575382c
......@@ -79,6 +79,16 @@ extern "C" {
#define MU_ERR_AUTH_FAILURE (MU_ERR_BASE + 32)
/* Authentication failed */
#define MU_ERR_PROCESS_NOEXEC (MU_ERR_BASE + 33)
/* Unable to execute subprocess */
#define MU_ERR_PROCESS_EXITED (MU_ERR_BASE + 34)
/* Subprocess exited with a non-zero status */
#define MU_ERR_PROCESS_SIGNALED (MU_ERR_BASE + 35)
/* Subprocess exited on signal */
#define MU_ERR_PROCESS_UNKNOWN_FAILURE (MU_ERR_BASE + 36)
/* Unknown failure while executing subprocess */
const char *mu_errname __P((int e));
const char *mu_strerror __P((int e));
......
......@@ -85,6 +85,11 @@ mu_errname (int e)
EN(MU_ERR_UNSAFE_PERMS);
EN(MU_ERR_BAD_AUTH_SCHEME);
EN(MU_ERR_AUTH_FAILURE);
EN(MU_ERR_PROCESS_NOEXEC);
EN(MU_ERR_PROCESS_EXITED);
EN(MU_ERR_PROCESS_SIGNALED);
EN(MU_ERR_PROCESS_UNKNOWN_FAILURE);
}
return "SYSTEM ERROR";
......@@ -140,6 +145,12 @@ mu_strerror (int e)
ES(MU_ERR_UNSAFE_PERMS, _("Unsafe file permissions. Set 0600."));
ES(MU_ERR_BAD_AUTH_SCHEME, _("Unsupported authentication scheme"));
ES(MU_ERR_AUTH_FAILURE, _("Authentication failed"));
ES(MU_ERR_PROCESS_NOEXEC, _("Cannot execute"));
ES(MU_ERR_PROCESS_EXITED, _("Process exited with a non-zero status"));
ES(MU_ERR_PROCESS_SIGNALED, _("Process exited on signal"));
ES(MU_ERR_PROCESS_UNKNOWN_FAILURE,
_("Unknown failure while executing subprocess"));
}
return strerror (e);
......