Skip to content
Snippets Groups Projects
Commit aae93b6e authored by Lubos Slovak's avatar Lubos Slovak
Browse files

Added new error code to knot errors.

refs #583
parent d55bfe14
No related branches found
No related tags found
No related merge requests found
......@@ -3,26 +3,27 @@
const error_table_t knot_error_msgs[] = {
/* Mapped errors. */
{KNOT_EOK, "OK"},
{KNOT_ENOMEM, "Not enough memory."},
{KNOT_EINVAL, "Invalid parameter passed."},
{KNOT_ENOTSUP, "Parameter not supported."},
{KNOT_EBUSY, "Requested resource is busy."},
{KNOT_EAGAIN, "The system lacked the necessary resource, try again."},
{KNOT_EACCES, "Permission to perform requested operation is denied."},
{KNOT_ECONNREFUSED, "Connection is refused."},
{KNOT_EISCONN, "Already connected."},
{KNOT_EADDRINUSE, "Address already in use."},
{KNOT_ENOENT, "Resource not found."},
{KNOT_ERANGE, "Value is out of range."},
/* Mapped errors. */
{KNOT_EOK, "OK"},
{KNOT_ENOMEM, "Not enough memory."},
{KNOT_EINVAL, "Invalid parameter passed."},
{KNOT_ENOTSUP, "Parameter not supported."},
{KNOT_EBUSY, "Requested resource is busy."},
{KNOT_EAGAIN, "The system lacked the necessary resource, try again."},
{KNOT_EACCES, "Permission to perform requested operation is denied."},
{KNOT_ECONNREFUSED, "Connection is refused."},
{KNOT_EISCONN, "Already connected."},
{KNOT_EADDRINUSE, "Address already in use."},
{KNOT_ENOENT, "Resource not found."},
{KNOT_ERANGE, "Value is out of range."},
/* Custom errors. */
{KNOT_ERROR, "Generic error."},
{KNOT_EADDRINVAL, "Invalid address."},
{KNOT_EZONEINVAL, "Invalid zone file."},
{KNOT_ENOTRUNNING, "Resource is not running."},
{KNOT_EPARSEFAIL, "Parser failed."},
{KNOT_ENOIPV6, "IPv6 support disabled."},
{KNOT_ERROR, 0}
/* Custom errors. */
{KNOT_ERROR, "Generic error."},
{KNOT_EADDRINVAL, "Invalid address."},
{KNOT_EZONEINVAL, "Invalid zone file."},
{KNOT_ENOTRUNNING, "Resource is not running."},
{KNOT_EPARSEFAIL, "Parser failed."},
{KNOT_ENOIPV6, "IPv6 support disabled."},
{KNOT_EMALF, "Malformed packet."},
{KNOT_ERROR, 0}
};
......@@ -45,9 +45,10 @@ enum knot_error_t {
KNOT_EZONEINVAL, /*!< \brief Invalid zone file. */
KNOT_ENOTRUNNING, /*!< \brief Resource is not running. */
KNOT_EPARSEFAIL, /*!< \brief Parser fail. */
KNOT_ENOIPV6, /*! \brief No IPv6 support. */
KNOT_ENOIPV6, /*!< \brief No IPv6 support. */
KNOT_EMALF, /*!< Malformed packet. */
KNOT_ERROR_COUNT = 19
KNOT_ERROR_COUNT = 20
};
/*! \brief Table linking error messages to error codes. */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment