source: buchla-68k/libsm/strpbrk.c@ f806726

Last change on this file since f806726 was b28a12e, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Zero redundant declarations.

  • Property mode set to 100644
File size: 605 bytes
RevLine 
[f40a309]1/*
2 =============================================================================
3 strpbrk.c -- find a 'break' character in a string
4 Version 1 -- 1987-06-12
5
6 Return ptr to first occurance of any character from `brkset'
7 in the character string `string'; NULL if none exists.
8 =============================================================================
9*/
10
[b28a12e]11#include "ram.h"
[6262b5c]12
[7258c6a]13int8_t *strpbrk(int8_t *string, int8_t *brkset)
[f40a309]14{
[7258c6a]15 register int8_t *p;
[f40a309]16
17 do {
18
19 for (p = brkset; *p != '\0' && *p != *string; ++p)
20 ;
21
22 if (*p != '\0')
23 return(string);
24 }
25
26 while(*string++)
27 ;
28
[7258c6a]29 return((int8_t *)0);
[f40a309]30}
[7258c6a]31
Note: See TracBrowser for help on using the repository browser.