Skip to content
Snippets Groups Projects
Commit a3dcda2a authored by Marek Vavruša's avatar Marek Vavruša
Browse files

errcode: added ETIMEOUT error code

parent aaadeb06
No related branches found
No related tags found
No related merge requests found
......@@ -66,6 +66,7 @@ const error_table_t knot_error_msgs[] = {
{ KNOT_EXFRREFUSED, "Zone transfer refused by the server." },
{ KNOT_EDENIED, "Not allowed." },
{ KNOT_ECONN, "Connection reset." },
{ KNOT_ETIMEOUT, "Connection timeout." },
{ KNOT_EIXFRSPACE, "IXFR reply did not fit in." },
{ KNOT_ECNAME, "CNAME loop found in zone." },
{ KNOT_ENODIFF, "Cannot create zone diff." },
......
......@@ -85,6 +85,7 @@ enum knot_error {
KNOT_EXFRREFUSED, /*!< Zone transfer refused by the server. */
KNOT_EDENIED, /*!< Not allowed. */
KNOT_ECONN, /*!< Connection reset. */
KNOT_ETIMEOUT, /*!< Connection timeout. */
KNOT_EIXFRSPACE, /*!< IXFR reply did not fit in. */
KNOT_ECNAME, /*!< CNAME loop found in zone. */
KNOT_ENODIFF, /*!< No zone diff can be created. */
......
......@@ -242,7 +242,7 @@ int tcp_recv_data(int fd, uint8_t *buf, int len, struct timeval *timeout)
if (ret) {
continue;
} else {
return KNOT_EBUSY;
return KNOT_ETIMEOUT;
}
} else {
return KNOT_ECONN;
......
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