From 6ea1b68db186036e9f05c06915f8c4bd757c3a25 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sat, 5 Nov 2011 17:28:48 +0900 Subject: Added SocketBuffer::pushStrSwap --- src/HttpServerCommand.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/HttpServerCommand.cc') diff --git a/src/HttpServerCommand.cc b/src/HttpServerCommand.cc index 4dd43a7c..9cb0ebe1 100644 --- a/src/HttpServerCommand.cc +++ b/src/HttpServerCommand.cc @@ -123,9 +123,10 @@ bool HttpServerCommand::execute() } if(!httpServer_->authenticate()) { httpServer_->disableKeepAlive(); + std::string text; httpServer_->feedResponse("401 Unauthorized", "WWW-Authenticate: Basic realm=\"aria2\"", - "","text/html"); + text,"text/html"); Command* command = new HttpServerResponseCommand(getCuid(), httpServer_, e_, socket_); e_->addCommand(command); -- cgit