- sprintf (buf, "%.1f%c", adjust_value (inexact_style, damt),
- suffixes[power]);
- if (4 < strlen (buf))
- sprintf (buf, "%.0f%c",
- adjust_value (inexact_style, damt * 10) / 10,
- suffixes[power]);
+ suffix[2] = '\0';
+ psuffix = generate_suffix_backwards (suffix + 2, power, base);
+ sprintf (buf, "%.1f%s",
+ adjust_value (inexact_style, damt), psuffix);
+ if (4 + (base == 1000) < strlen (buf))
+ sprintf (buf, "%.0f%s",
+ adjust_value (inexact_style, damt * 10) / 10, psuffix);