Telemetry leaks strings

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
7 years ago
11 months ago

People

(Reporter: glandium, Unassigned)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

7 years ago
I noticed this when valgrinding for something else. There are a bunch of leaked strings all coming from the same kind of backtrace:

==26636==    at 0x4C27297: operator new(unsigned long) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==26636==    by 0x5505FC8: std::string::_Rep::_S_create(unsigned long, unsigned long, std::allocator<char> const&) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
==26636==    by 0x55079D4: char* std::string::_S_construct<char const*>(char const*, char const*, std::allocator<char> const&, std::forward_iterator_tag) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
==26636==    by 0x5507B22: std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string(char const*, std::allocator<char> const&) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
==26636==    by 0x1255FCDE: (anonymous namespace)::HistogramGet(char const*, unsigned int, unsigned int, unsigned int, unsigned int, base::Histogram**) (Telemetry.cpp:178)
==26636==    by 0x1255FD8A: (anonymous namespace)::GetHistogramByEnumId(mozilla::Telemetry::ID, base::Histogram**) (Telemetry.cpp:201)
==26636==    by 0x125600A4: mozilla::Telemetry::Accumulate(mozilla::Telemetry::ID, unsigned int) (Telemetry.cpp:649)

This adds noise to valgrind leak detection output, which is not very nice.
Does this have anything to do with the comments in histogram.cc stating that histograms will be leaked to avoid racy destruction at shutdown?
Duplicate of this bug: 711217
I think this may be a dup of 824647, even though the stacks are different; the allocations are in roughly the same place and I think the same patch suffices for fixing both of them.
Closing this. It was fixed by the dependencies of bug 1277552.
Status: NEW → RESOLVED
Last Resolved: 11 months ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.