diff --git a/src/nlsr.cpp b/src/nlsr.cpp
index 384d4e9..71970ec 100644
--- a/src/nlsr.cpp
+++ b/src/nlsr.cpp
@@ -165,13 +165,13 @@
 {
   if (currentNeighbor != m_adjacencyList.getAdjList().end()) {
     ndn::FaceUri uri(currentNeighbor->getFaceUri());
-    uri.canonize([this, then, currentNeighbor] (ndn::FaceUri canonicalUri) {
+    uri.canonize([then, currentNeighbor] (ndn::FaceUri canonicalUri) {
         NLSR_LOG_DEBUG("Canonized URI: " << currentNeighbor->getFaceUri()
                    << " to: " << canonicalUri);
         currentNeighbor->setFaceUri(canonicalUri);
         then(std::next(currentNeighbor));
       },
-      [this, then, currentNeighbor] (const std::string& reason) {
+      [then, currentNeighbor] (const std::string& reason) {
         NLSR_LOG_ERROR("Could not canonize URI: " << currentNeighbor->getFaceUri()
                    << " because: " << reason);
         then(std::next(currentNeighbor));
diff --git a/tests/test-fib.cpp b/tests/test-fib.cpp
index d47d3a8..629f933 100644
--- a/tests/test-fib.cpp
+++ b/tests/test-fib.cpp
@@ -308,8 +308,8 @@
   int origSeqNo = fe.getSeqNo();
 
   fib->scheduleEntryRefresh(fe,
-                            [&, this] (FibEntry& entry) {
-                              BOOST_CHECK_EQUAL(origSeqNo+1, entry.getSeqNo());
+                            [&] (FibEntry& entry) {
+                              BOOST_CHECK_EQUAL(origSeqNo + 1, entry.getSeqNo());
                             });
   this->advanceClocks(ndn::time::milliseconds(10), 1);
 }
diff --git a/tests/test-nlsr.cpp b/tests/test-nlsr.cpp
index 5c91312..efab71f 100644
--- a/tests/test-nlsr.cpp
+++ b/tests/test-nlsr.cpp
@@ -452,8 +452,7 @@
       nlsr.canonizeNeighborUris(iterator, thenCallback, finallyCallback);
   };
   nlsr.canonizeNeighborUris(nlsr.getAdjacencyList().getAdjList().begin(),
-                            [&thenCallback, &finallyCallback]
-                            (std::list<Adjacent>::iterator iterator) {
+                            [&] (std::list<Adjacent>::iterator iterator) {
                               thenCallback(iterator);
                             },
                             finallyCallback);
diff --git a/tests/test-sync-logic-handler.cpp b/tests/test-sync-logic-handler.cpp
index b233b22..9f8192e 100644
--- a/tests/test-sync-logic-handler.cpp
+++ b/tests/test-sync-logic-handler.cpp
@@ -111,7 +111,7 @@
 
     // Actual testing done here -- signal function callback
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [&, this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_CHECK_EQUAL(ndn::Name{updateName}, routerName);
         BOOST_CHECK_EQUAL(sequenceNumber, syncSeqNo);
       });
@@ -139,7 +139,7 @@
       + OTHER_ROUTER_NAME + std::to_string(lsaType);
 
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [& ,this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_CHECK_EQUAL(ndn::Name{updateName}, routerName);
         BOOST_CHECK_EQUAL(sequenceNumber, syncSeqNo);
       });
@@ -166,7 +166,7 @@
       + OTHER_ROUTER_NAME + std::to_string(lsaType);
 
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [& ,this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_CHECK_EQUAL(ndn::Name{updateName}, routerName);
         BOOST_CHECK_EQUAL(sequenceNumber, syncSeqNo);
       });
@@ -193,7 +193,7 @@
     updateName.append(CONFIG_SITE).append(CONFIG_ROUTER_NAME).append(std::to_string(lsaType));
 
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [& ,this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_FAIL("Updates for self should not be emitted!");
       });
 
@@ -217,7 +217,7 @@
     updateName.append(CONFIG_ROUTER_NAME).append(std::to_string(lsaType));
 
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [& ,this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_FAIL("Malformed updates should not be emitted!");
       });
 
@@ -240,7 +240,7 @@
   SyncLogicHandler sync{face, testLsaAlwaysFalse, conf};
   sync.createSyncSocket(conf.getChronosyncPrefix());
     ndn::util::signal::ScopedConnection connection = sync.onNewLsa->connect(
-      [& ,this] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
+      [&] (const ndn::Name& routerName, const uint64_t& sequenceNumber) {
         BOOST_FAIL("An update for an LSA with non-new sequence number should not emit!");
       });
 
