| 102 | } |
| 103 | |
| 104 | unsigned |
| 105 | HttpGetContentLength(TSMBuffer mbuf, TSMLoc mhdr) |
| 106 | { |
| 107 | TSMLoc mloc; |
| 108 | unsigned value = 0; |
| 109 | |
| 110 | mloc = TSMimeHdrFieldFind(mbuf, mhdr, TS_MIME_FIELD_CONTENT_LENGTH, -1); |
| 111 | if (mloc != TS_NULL_MLOC) { |
| 112 | value = TSMimeHdrFieldValueUintGet(mbuf, mhdr, mloc, 0 /* index */); |
| 113 | } |
| 114 | |
| 115 | TSHandleMLocRelease(mbuf, mhdr, mloc); |
| 116 | return value; |
| 117 | } |
| 118 | |
| 119 | bool |
| 120 | HttpIsChunkedEncoding(TSMBuffer mbuf, TSMLoc mhdr) |
no test coverage detected