Skip to content

SIGSEGV on startup with large value of --max-stats if total stats size is greater than 2^32 #3463

@ggreenway

Description

@ggreenway

Repro steps:
envoy --max-stats 10000000000

Call Stack:

#0  0x00000000007784cc in Envoy::BlockMemoryHashSet<Envoy::Stats::RawStatData>::initialize (this=0x255ffa0, options=...)
    at bazel-out/k8-dbg/bin/source/common/common/_virtual_includes/block_memory_hash_set_lib/common/common/block_memory_hash_set.h:232
#1  0x0000000000777074 in Envoy::BlockMemoryHashSet<Envoy::Stats::RawStatData>::BlockMemoryHashSet (this=0x255ffa0, options=..., init=true, memory=0x7fffc78760c8 "")
    at bazel-out/k8-dbg/bin/source/common/common/_virtual_includes/block_memory_hash_set_lib/common/common/block_memory_hash_set.h:73
#2  0x0000000000773825 in Envoy::Server::HotRestartImpl::HotRestartImpl (this=0x25c2400, options=...) at source/server/hot_restart_impl.cc:127
#3  0x00000000004333c6 in Envoy::MainCommonBase::MainCommonBase (this=0x25b8998, options=...) at source/exe/main_common.cc:52
#4  0x0000000000433acc in Envoy::MainCommon::MainCommon (this=0x25b8500, argc=3, argv=0x7fffffffe438) at source/exe/main_common.cc:97
#5  0x0000000000422b6e in std::make_unique<Envoy::MainCommon, int&, char**&> () at /usr/include/c++/5/bits/unique_ptr.h:765
#6  0x0000000000419c9e in main (argc=3, argv=0x7fffffffe438) at source/exe/main.cc:19

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions