summaryrefslogtreecommitdiff
path: root/src/mongo/db/dbwebserver.h
diff options
context:
space:
mode:
authorKaloian Manassiev <kaloian.manassiev@mongodb.com>2015-03-26 17:47:53 -0400
committerKaloian Manassiev <kaloian.manassiev@mongodb.com>2015-03-27 11:59:31 -0400
commite29ff8af63903ee88f44ad38cac780bd20cf6543 (patch)
tree8e7a5a49d95f06966fed5e595909a194027cae1b /src/mongo/db/dbwebserver.h
parent0fb262fb082e1a8b64bb1f5c0099ed2ee4c432d9 (diff)
downloadmongo-e29ff8af63903ee88f44ad38cac780bd20cf6543.tar.gz
SERVER-17761 DbWebServer should own the AdminAccess pointer
Diffstat (limited to 'src/mongo/db/dbwebserver.h')
-rw-r--r--src/mongo/db/dbwebserver.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mongo/db/dbwebserver.h b/src/mongo/db/dbwebserver.h
index b1c8529024a..0f4b6625194 100644
--- a/src/mongo/db/dbwebserver.h
+++ b/src/mongo/db/dbwebserver.h
@@ -35,6 +35,7 @@
#include <string>
#include <vector>
+#include "mongo/base/disallow_copying.h"
#include "mongo/util/net/miniwebserver.h"
#include "mongo/util/net/sock.h"
@@ -54,6 +55,7 @@ namespace mongo {
};
class DbWebHandler : public Prioritizable {
+ MONGO_DISALLOW_COPYING(DbWebHandler);
public:
DbWebHandler( const std::string& name , double priority , bool requiresREST );
virtual ~DbWebHandler() {}
@@ -107,7 +109,7 @@ namespace mongo {
class DbWebServer : public MiniWebServer {
public:
- DbWebServer(const std::string& ip, int port, const AdminAccess* webUsers);
+ DbWebServer(const std::string& ip, int port, AdminAccess* webUsers);
private:
virtual void doRequest(const char *rq,
@@ -127,8 +129,7 @@ namespace mongo {
std::vector<std::string>& headers);
- // not owned here
- const AdminAccess* _webUsers;
+ const boost::scoped_ptr<AdminAccess> _webUsers;
};
void webServerListenThread(boost::shared_ptr<DbWebServer> dbWebServer);