- // Remove tab from section name prefix. This is necessary becase TAI
- // sometimes return a section name prefixed with elf unused chars. This is
- // a little bit dirty. FIXME: find a better approach, maybe add more
- // methods to TAI to get the clean name?
- void fixNameForSection(std::string &Name) {
- size_t Pos = Name.find("\t");
- if (Pos != std::string::npos)
- Name.erase(Pos, 1);
-
- Pos = Name.find(".section ");
- if (Pos != std::string::npos)
- Name.erase(Pos, 9);
-
- Pos = Name.find("\n");
- if (Pos != std::string::npos)
- Name.erase(Pos, 1);
- }
-