------------------------------------------------------------ revno: 12972 revision-id: squid3@treenet.co.nz-20130803041504-5gc3q5c4v7sprhyi parent: squid3@treenet.co.nz-20130801204556-ydwbv6f5wciytnjt committer: Amos Jeffries branch nick: trunk timestamp: Sat 2013-08-03 16:15:04 +1200 message: Cleanup: initialize all member of AnyP::PortCfg Detected by Coverity Scan. Issue 1058883. ------------------------------------------------------------ # Bazaar merge directive format 2 (Bazaar 0.90) # revision_id: squid3@treenet.co.nz-20130803041504-5gc3q5c4v7sprhyi # target_branch: http://bzr.squid-cache.org/bzr/squid3/trunk/ # testament_sha1: 5f22c6ca2601c9e5cc36b5589b6d98fb1b8f9984 # timestamp: 2013-08-03 06:17:59 +0000 # source_branch: http://bzr.squid-cache.org/bzr/squid3/trunk/ # base_revision_id: squid3@treenet.co.nz-20130801204556-\ # ydwbv6f5wciytnjt # # Begin patch === modified file 'src/anyp/PortCfg.cc' --- src/anyp/PortCfg.cc 2013-07-26 02:06:25 +0000 +++ src/anyp/PortCfg.cc 2013-08-03 04:15:04 +0000 @@ -18,13 +18,50 @@ AnyP::PortCfg::PortCfg() : next(NULL), + s(), transport(AnyP::PROTO_HTTP,1,1), // "Squid is an HTTP proxy", etc. name(NULL), - defaultsite(NULL) + defaultsite(NULL), + flags(), + allow_direct(false), + vhost(false), + actAsorigin(false), + ignore_cc(false), + connection_auth_disabled(false), + vport(0), + disable_pmtu_discovery(0), + listenConn() #if USE_SSL - ,dynamicCertMemCacheSize(std::numeric_limits::max()) + ,cert(NULL), + key(NULL), + version(0), + cipher(NULL), + options(NULL), + clientca(NULL), + cafile(NULL), + capath(NULL), + crlfile(NULL), + dhfile(NULL), + sslflags(NULL), + sslContextSessionId(NULL), + generateHostCertificates(false), + dynamicCertMemCacheSize(std::numeric_limits::max()), + staticSslContext(), + signingCert(), + signPkey(), + certsToChain(), + untrustedSigningCert(), + untrustedSignPkey(), + clientVerifyCrls(), + clientCA(), + dhParams(), + contextMethod(), + sslContextFlags(0), + sslOptions(0) #endif -{} +{ + memset(&tcp_keepalive, 0, sizeof(tcp_keepalive)); +} AnyP::PortCfg::~PortCfg() {