chiark
/
gitweb
/
~mdw
/
qmail
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
addrcheck: Take the domain as following the last `@', not the first.
[qmail]
/
case_diffb.c
1
#include "case.h"
2
3
int case_diffb(s,len,t)
4
register char *s;
5
unsigned int len;
6
register char *t;
7
{
8
register unsigned char x;
9
register unsigned char y;
10
11
while (len > 0) {
12
--len;
13
x = *s++ - 'A';
14
if (x <= 'Z' - 'A') x += 'a'; else x += 'A';
15
y = *t++ - 'A';
16
if (y <= 'Z' - 'A') y += 'a'; else y += 'A';
17
if (x != y)
18
return ((int)(unsigned int) x) - ((int)(unsigned int) y);
19
}
20
return 0;
21
}