When you overload operator new (or delete, or sometimes malloc but not all the time because malloc is weird), the symbol will be force exported by whatever the shit ass linker being used is.
- This causes any offsets to the function in the GOT/PLT to be overwritten with a pointer to a PLT wrapper that branches to the end of the .text section (text_end) before relocation, which should not matter usually but does here because JMPREL relocations are being used instead of RELA relocations which would overwrite the offset with a correct one built from the module base and offset in the RELA entry instead of the invalid offset that is now sitting in the PLT. (No clue why this happens or where it happens, but it can be observed when reading PLT values before runtime in GDB)
- This causes the function to be viewed as an import by RTLD and will overwrite the PLT offsets with offsets to functions with the same symbol in other modules
This can be worked around by adding the affected symbols to a version script as "local" symbols, which prevents them from being exported. I don't expect you to fix this or know why it's happening, but just writing it down for the record
When you overload operator new (or delete, or sometimes malloc but not all the time because malloc is weird), the symbol will be force exported by whatever the shit ass linker being used is.
This can be worked around by adding the affected symbols to a version script as "local" symbols, which prevents them from being exported. I don't expect you to fix this or know why it's happening, but just writing it down for the record