FIxing the address sanitizer issue reported in https://github.com/llvm/llvm-project/pull/91548 . The problem comes from the assignment `auto bodyData = newSectionData` which defaults to `SmallVector<uint8_t> data = newSectionData` - which actually creates a copy of the data, placed on the stack. By explicitly using `ArrayRef` instead, we make sure that the original copy is used. We also change the assignment in `ObjcCategoryMerger::newStringData` from `auto` to `SmallVector<uint8_t> &` to make it explicit.
51 KiB
51 KiB