In all .cpp files, remove using namespace ndn::ptr_lib and explicitly use ptr_lib::shared_ptr and make_shared.
diff --git a/src/encoding/der/visitor/certificate-data-visitor.cpp b/src/encoding/der/visitor/certificate-data-visitor.cpp
index 4270d68..7edf794 100644
--- a/src/encoding/der/visitor/certificate-data-visitor.cpp
+++ b/src/encoding/der/visitor/certificate-data-visitor.cpp
@@ -18,7 +18,6 @@
#include "certificate-data-visitor.hpp"
using namespace std;
-using namespace ndn::ptr_lib;
INIT_LOGGER("ndn.der.CertificateDataVisitor");
@@ -41,7 +40,7 @@
children[1]->accept(subjectVisitor, param);
PublicKeyVisitor pubkeyVisitor;
Certificate* certData = ndnboost::any_cast<Certificate*>(param);
- certData->setPublicKeyInfo(*ndnboost::any_cast<shared_ptr<PublicKey> >(children[2]->accept(pubkeyVisitor)));
+ certData->setPublicKeyInfo(*ndnboost::any_cast<ptr_lib::shared_ptr<PublicKey> >(children[2]->accept(pubkeyVisitor)));
if(children.size() > 3)
{
diff --git a/src/encoding/der/visitor/public-key-visitor.cpp b/src/encoding/der/visitor/public-key-visitor.cpp
index a2eab56..a5f5542 100644
--- a/src/encoding/der/visitor/public-key-visitor.cpp
+++ b/src/encoding/der/visitor/public-key-visitor.cpp
@@ -12,7 +12,6 @@
#include "public-key-visitor.hpp"
using namespace std;
-using namespace ndn::ptr_lib;
namespace ndn {
@@ -24,10 +23,10 @@
DerNodePtrList& children = derSeq.getChildren();
SimpleVisitor simpleVisitor;
- shared_ptr<DerSequence> algoSeq = dynamic_pointer_cast<DerSequence>(children[0]);
+ ptr_lib::shared_ptr<DerSequence> algoSeq = ptr_lib::dynamic_pointer_cast<DerSequence>(children[0]);
OID algorithm = ndnboost::any_cast<OID>(algoSeq->getChildren()[0]->accept(simpleVisitor));
Blob raw = derSeq.getRaw();
- return ndnboost::any(shared_ptr<PublicKey>(new PublicKey(algorithm, raw)));
+ return ndnboost::any(ptr_lib::shared_ptr<PublicKey>(new PublicKey(algorithm, raw)));
}
} // der