s/qmail  3.3.23
Next generation secure email transport
byte_rchr.c
Go to the documentation of this file.
1 #include "byte.h"
2 
3 unsigned int byte_rchr(char *s,register unsigned int n,int c)
4 {
5  register char ch;
6  register char *t;
7  register char *u;
8 
9  ch = c;
10  t = s;
11  u = 0;
12  for (;;) {
13  if (!n) break; if (*t == ch) u = t; ++t; --n;
14  if (!n) break; if (*t == ch) u = t; ++t; --n;
15  if (!n) break; if (*t == ch) u = t; ++t; --n;
16  if (!n) break; if (*t == ch) u = t; ++t; --n;
17  }
18  if (!u) u = t;
19  return u - s;
20 }
unsigned int byte_rchr(char *s, register unsigned int n, int c)
Definition: byte_rchr.c:3
unsigned n
Definition: matchup.c:36
unsigned u
Definition: matchup.c:36