summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorng0 <ng0@n0.is>2019-08-02 11:31:30 +0000
committerng0 <ng0@n0.is>2019-08-02 11:31:30 +0000
commit8b1e8793379015ae3ef32e02234467c6e539b448 (patch)
treed3de04a701d7c0bce60d24a12e6013d601a77940
parent818b0a791b3e48cce9da91a1aa136ce2b65e8aaf (diff)
fix a couple of fixmes: add log messages.
-rw-r--r--src/microhttpd/mhd_send.c28
1 files changed, 24 insertions, 4 deletions
diff --git a/src/microhttpd/mhd_send.c b/src/microhttpd/mhd_send.c
index 0b1ae127..928e92cb 100644
--- a/src/microhttpd/mhd_send.c
+++ b/src/microhttpd/mhd_send.c
@@ -81,10 +81,20 @@ pre_cork_setsockopt (struct MHD_Connection *connection,
/* FIXME: optlen invalid, should at least log this, maybe die */
break;
case EFAULT:
- /* FIXME: wopsie, should at leats log this, maybe die */
+ /* wopsie, should at leats log this, FIXME: maybe die */
+#ifdef HAVE_MESSAGES
+ MHD_DLOG (daemon,
+ _("The addresss pointed to by optval is not a valid part of the process address space: %s\n"),
+ MHD_socket_last_strerr_());
+#endif
break;
case ENOPROTOOPT:
- /* FIXME: optlen unknown, should at least log this */
+ /* optlen unknown, should at least log this */
+#ifdef HAVE_MESSAGES
+ MHD_DLOG (daemon,
+ _("The option is unknown: %s\n"),
+ MHD_socket_last_strerr_());
+#endif
break;
default:
/* any others? man page does not list more... */
@@ -152,10 +162,20 @@ post_cork_setsockopt (struct MHD_Connection *connection,
/* FIXME: optlen invalid, should at least log this, maybe die */
break;
case EFAULT:
- /* FIXME: wopsie, should at leats log this, maybe die */
+ /* wopsie, should at leats log this, FIXME: maybe die */
+#ifdef HAVE_MESSAGES
+ MHD_DLOG (daemon,
+ _("The addresss pointed to by optval is not a valid part of the process address space: %s\n"),
+ MHD_socket_last_strerr_());
+#endif
break;
case ENOPROTOOPT:
- /* FIXME: optlen unknown, should at least log this */
+ /* optlen unknown, should at least log this */
+#ifdef HAVE_MESSAGES
+ MHD_DLOG (daemon,
+ _("The option is unknown: %s\n"),
+ MHD_socket_last_strerr_());
+#endif
break;
default:
/* any others? man page does not list more... */