We would better be prepared for 'm' being the first character of the
incoming string.
{
case 'a':
attr |= SHF_ALLOC;
+ /* Compatibility. */
+ if (len > 1 && str[1] == 'm')
+ {
+ attr |= SHF_MERGE;
+ str++, len--;
+ if (len > 1 && str[1] == 's')
+ {
+ attr |= SHF_STRINGS;
+ str++, len--;
+ }
+ }
break;
case 'e':
attr |= SHF_EXCLUDE;
case '?':
*is_clone = true;
break;
- /* Compatibility. */
- case 'm':
- if (*(str - 1) == 'a')
- {
- attr |= SHF_MERGE;
- if (len > 1 && str[1] == 's')
- {
- attr |= SHF_STRINGS;
- str++, len--;
- }
- break;
- }
- /* Fall through. */
default:
{
const char *bad_msg = _("unrecognized .section attribute:"