aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-07-02 21:56:55 +0200
committerChristian Grothoff <christian@grothoff.org>2020-07-02 21:56:55 +0200
commit860b42e9180da4dcd7e8690a3fcdb4e37e5772c5 (patch)
treeff37ecdb57fc300ef3d53d623f6f01786f237f37
parenta110ae6276660bee3caab30e9ff3f12f85cf3241 (diff)
downloadlibmicrohttpd-860b42e9180da4dcd7e8690a3fcdb4e37e5772c5.tar.gz
libmicrohttpd-860b42e9180da4dcd7e8690a3fcdb4e37e5772c5.zip
fix return value of MHD_queue_basic_auth_fail_response
-rw-r--r--ChangeLog3
-rw-r--r--src/include/microhttpd.h2
-rw-r--r--src/microhttpd/basicauth.c4
3 files changed, 6 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 16e837b1..a4bafe30 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
1Thu 02 Jul 2020 09:56:23 PM CEST
2 Fixed return type of MHD_queue_basic_auth_fail_response. -CA/CG
3
1Sun 28 Jun 2020 09:36:01 PM CEST 4Sun 28 Jun 2020 09:36:01 PM CEST
2 Fix buffer overflow issue in URL parser. 5 Fix buffer overflow issue in URL parser.
3 Releasing libmicrohttpd 0.9.71. -CG 6 Releasing libmicrohttpd 0.9.71. -CG
diff --git a/src/include/microhttpd.h b/src/include/microhttpd.h
index 00d4f9bd..7de7686b 100644
--- a/src/include/microhttpd.h
+++ b/src/include/microhttpd.h
@@ -3733,7 +3733,7 @@ MHD_basic_auth_get_username_password (struct MHD_Connection *connection,
3733 * @return #MHD_YES on success, #MHD_NO otherwise 3733 * @return #MHD_YES on success, #MHD_NO otherwise
3734 * @ingroup authentication 3734 * @ingroup authentication
3735 */ 3735 */
3736_MHD_EXTERN int 3736_MHD_EXTERN enum MHD_Result
3737MHD_queue_basic_auth_fail_response (struct MHD_Connection *connection, 3737MHD_queue_basic_auth_fail_response (struct MHD_Connection *connection,
3738 const char *realm, 3738 const char *realm,
3739 struct MHD_Response *response); 3739 struct MHD_Response *response);
diff --git a/src/microhttpd/basicauth.c b/src/microhttpd/basicauth.c
index 3208ee8c..d9532d4a 100644
--- a/src/microhttpd/basicauth.c
+++ b/src/microhttpd/basicauth.c
@@ -120,12 +120,12 @@ MHD_basic_auth_get_username_password (struct MHD_Connection *connection,
120 * @return #MHD_YES on success, #MHD_NO otherwise 120 * @return #MHD_YES on success, #MHD_NO otherwise
121 * @ingroup authentication 121 * @ingroup authentication
122 */ 122 */
123int 123enum MHD_Result
124MHD_queue_basic_auth_fail_response (struct MHD_Connection *connection, 124MHD_queue_basic_auth_fail_response (struct MHD_Connection *connection,
125 const char *realm, 125 const char *realm,
126 struct MHD_Response *response) 126 struct MHD_Response *response)
127{ 127{
128 int ret; 128 enum MHD_Result ret;
129 int res; 129 int res;
130 size_t hlen = strlen (realm) + strlen ("Basic realm=\"\"") + 1; 130 size_t hlen = strlen (realm) + strlen ("Basic realm=\"\"") + 1;
131 char *header; 131 char *header;