strpbrk.c 428 B

12345678910111213141516171819
  1. /* Copyright (C) 1995,1996 Robert de Bath <rdebath@cix.compulink.co.uk>
  2. * This file is part of the Linux-8086 C library and is distributed
  3. * under the GNU Library General Public License.
  4. */
  5. #include <string.h>
  6. /* This uses strchr, strchr should be in assembler */
  7. char *strpbrk( const char *str, const char *set)
  8. {
  9. while (*str != '\0')
  10. if (strchr(set, *str) == 0)
  11. ++str;
  12. else
  13. return (char *) str;
  14. return 0;
  15. }