Re: Segment fault at exit when compiled with Clang and libc++
LdBeth <[email protected]> Wed, 31 Jan 2024 23:16:13 -0600
| Newsgroups | gmane.comp.gnu.gnucap.bugs |
|---|---|
| Message-ID | <[email protected]> |
>>>>> In <[email protected]> >>>>> LdBeth <[email protected]> wrote: ldb> Compiling the library with debug info can gives the backtrace. ldb> Actually, there are two places cause the segfault. Their backtraces ldb> leads to C++ std::less(), but I don't found that very helpful, so ldb> I tried my best to isolate the problem. I found the cause is this method in `l_indirect.h` size_t erase(void* b, void* e) { size_t c=0; assert(b <= e); for (void* i=b; i<=e; i=reinterpret_cast<bool*>(i)+1) { c += _map.erase(i); } return c; } Still, I have no idea on how to fix this.