3 static char *(hname
[]) = {
30 , "content-transfer-encoding"
31 , "notice-requested-upon-delivery-to"
36 static int hmatch(s
,len
,t
)
44 for (i
= 0;ch
= t
[i
];++i
)
46 if (i
>= len
) return 0;
49 if (ch
== '-') return 0;
50 if (ch
- 32 != s
[i
]) return 0;
55 if (i
>= len
) return 0;
57 if (ch
== ':') return 1;
58 if ((ch
!= ' ') && (ch
!= '\t')) return 0;
63 int hfield_known(s
,len
)
70 for (i
= 1;t
= hname
[i
];++i
)
76 int hfield_valid(s
,len
)
84 for (j
= 0;j
< len
;++j
)
87 if (j
>= len
) return 0;
91 if ((ch
!= ' ') && (ch
!= '\t'))
100 if (ch
<= 32) return 0;
101 if (ch
>= 127) return 0;
106 unsigned int hfield_skipname(s
,len
)
113 for (i
= 0;i
< len
;++i
)
120 if ((ch
!= '\t') && (ch
!= '\n') && (ch
!= '\r') && (ch
!= ' '))