1
0

string_suffix.c 388 B

12345678910111213141516171819202122
  1. /*
  2. * string_suffix.c
  3. */
  4. #include "private.h"
  5. #include "lub/ctype.h"
  6. /*--------------------------------------------------------- */
  7. const char *lub_string_suffix(const char *string)
  8. {
  9. const char *p1, *p2;
  10. p1 = p2 = string;
  11. while (*p1) {
  12. if (lub_ctype_isspace(*p1)) {
  13. p2 = p1;
  14. p2++;
  15. }
  16. p1++;
  17. }
  18. return p2;
  19. }
  20. /*--------------------------------------------------------- */