use std::make_shared where possible

may avoid extra alloc for ref. counter
This commit is contained in:
Michael Davidsaver
2019-12-19 13:55:40 -08:00
parent 71905b314b
commit 68cb777702
7 changed files with 10 additions and 10 deletions
+1 -1
View File
@@ -110,7 +110,7 @@ Server::Server(Config&& conf)
* Which need to safely access server storage, but should not
* prevent a server from stopping.
*/
std::shared_ptr<Pvt> internal(new Pvt(std::move(conf)));
auto internal(std::make_shared<Pvt>(std::move(conf)));
internal->internal_self = internal;
// external