summaryrefslogtreecommitdiff
path: root/server/src/httpd.cc
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/httpd.cc')
-rw-r--r--server/src/httpd.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/server/src/httpd.cc b/server/src/httpd.cc
index ce1a1ce..185ad9d 100644
--- a/server/src/httpd.cc
+++ b/server/src/httpd.cc
@@ -117,7 +117,13 @@ static int request_handler(void *cls,
i++;
}
- ret = MHD_queue_response(con, reply.status, rsp);
+ bool authfailed = true;
+ if(authfailed) {
+ ret = MHD_queue_basic_auth_fail_response(con, "my realm", rsp);
+ } else {
+ ret = MHD_queue_response(con, reply.status, rsp);
+ }
+
MHD_destroy_response(rsp);
}