Skip to content
This repository was archived by the owner on Dec 26, 2022. It is now read-only.

Commit a57260c

Browse files
JulianATAjserv
authored andcommitted
fix(http):Use precise error message in http.c
1 parent 64ce4ee commit a57260c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

connectivity/http/http.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#include <arpa/inet.h>
2+
#include <errno.h>
23
#include <microhttpd.h>
34
#include <regex.h>
45
#include <string.h>
@@ -486,7 +487,7 @@ status_t ta_http_start(ta_http_t *const http) {
486487
MHD_start_daemon(MHD_USE_AUTO_INTERNAL_THREAD | MHD_USE_THREAD_PER_CONNECTION | MHD_USE_ERROR_LOG | MHD_USE_DEBUG,
487488
atoi(http->core->ta_conf.port), request_log, NULL, ta_http_handler, http, MHD_OPTION_END);
488489
if (http->daemon == NULL) {
489-
ta_log_error("%s\n", "SC_HTTP_OOM");
490+
ta_log_error("%s\n", strerror(errno));
490491
return SC_HTTP_OOM;
491492
}
492493
return SC_OK;

0 commit comments

Comments
 (0)