fix static analyzer warings
diff --git a/compiler/cpp/src/thrift/generate/t_delphi_generator.cc b/compiler/cpp/src/thrift/generate/t_delphi_generator.cc
index 8bd77e8..737aa5a 100644
--- a/compiler/cpp/src/thrift/generate/t_delphi_generator.cc
+++ b/compiler/cpp/src/thrift/generate/t_delphi_generator.cc
@@ -670,10 +670,8 @@
   delphi_reserved_method["instancesize"] = 1;
   delphi_reserved_method["inheritsfrom"] = 1;
   delphi_reserved_method["methodaddress"] = 1;
-  delphi_reserved_method["methodaddress"] = 1;
   delphi_reserved_method["methodname"] = 1;
   delphi_reserved_method["fieldaddress"] = 1;
-  delphi_reserved_method["fieldaddress"] = 1;
   delphi_reserved_method["getinterface"] = 1;
   delphi_reserved_method["getinterfaceentry"] = 1;
   delphi_reserved_method["getinterfacetable"] = 1;
diff --git a/lib/cpp/src/thrift/server/TNonblockingServer.cpp b/lib/cpp/src/thrift/server/TNonblockingServer.cpp
index 31ff2a9..bee3e3b 100644
--- a/lib/cpp/src/thrift/server/TNonblockingServer.cpp
+++ b/lib/cpp/src/thrift/server/TNonblockingServer.cpp
@@ -1285,7 +1285,7 @@
 }
 
 bool TNonblockingIOThread::notify(TNonblockingServer::TConnection* conn) {
-  THRIFT_SOCKET fd = getNotificationSendFD();
+  auto fd = getNotificationSendFD();
   if (fd < 0) {
     return false;
   }
diff --git a/lib/cpp/test/AllProtocolTests.tcc b/lib/cpp/test/AllProtocolTests.tcc
index a7eab07..80a4ea0 100644
--- a/lib/cpp/test/AllProtocolTests.tcc
+++ b/lib/cpp/test/AllProtocolTests.tcc
@@ -216,7 +216,7 @@
     testMessage<TProto>();
 
     printf("%s => OK\n", protoname);
-  } catch (TException e) {
+  } catch (const TException &e) {
     THRIFT_SNPRINTF(errorMessage, ERR_LEN, "%s => Test FAILED: %s", protoname, e.what());
     throw TException(errorMessage);
   }
diff --git a/lib/cpp/test/OneWayHTTPTest.cpp b/lib/cpp/test/OneWayHTTPTest.cpp
index 89fa164..f369d8c 100644
--- a/lib/cpp/test/OneWayHTTPTest.cpp
+++ b/lib/cpp/test/OneWayHTTPTest.cpp
@@ -227,7 +227,7 @@
     blockable_transport->flush() ;
     try {
       client.recv_roundTripRPC() ;
-    } catch (TTransportException e) {
+    } catch (const TTransportException &e) {
       BOOST_ERROR( "we should not get a transport exception -- this means we failed: " + std::string(e.what()) ) ;
     }
     transport->close();
diff --git a/lib/cpp/test/TransportTest.cpp b/lib/cpp/test/TransportTest.cpp
index 3872071..0d900d9 100644
--- a/lib/cpp/test/TransportTest.cpp
+++ b/lib/cpp/test/TransportTest.cpp
@@ -726,9 +726,7 @@
   BOOST_REQUIRE(transports.in != NULL);
   BOOST_REQUIRE(transports.out != NULL);
 
-  uint8_t write_buf[16];
   uint8_t read_buf[16];
-  memset(write_buf, 'a', sizeof(write_buf));
 
   // Attempting to read when no data is available should either block until
   // some data is available, or fail immediately.  (e.g., TSocket blocks,