summaryrefslogtreecommitdiff
path: root/ctx.c
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2016-08-28 23:23:10 -0400
committerPaul Duncan <pabs@pablotron.org>2016-08-28 23:23:10 -0400
commit0308b0cc9fab95f0f12aa874ae1fcded31d7f573 (patch)
tree47e40528e1439e161b3f855e2bab7c7233b6d94a /ctx.c
parent845ddb43da8aa2a8c80a9d9638d63386ddf97d7e (diff)
downloadlibfhp-0308b0cc9fab95f0f12aa874ae1fcded31d7f573.tar.bz2
libfhp-0308b0cc9fab95f0f12aa874ae1fcded31d7f573.zip
add content-type parser
Diffstat (limited to 'ctx.c')
-rw-r--r--ctx.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ctx.c b/ctx.c
index d2d7245..60b379e 100644
--- a/ctx.c
+++ b/ctx.c
@@ -112,6 +112,7 @@ static const fhp_ctx_t FHP_CTX_DEFAULT = {
.body_type = FHP_BODY_TYPE_NONE,
.content_length = 0,
.num_tes = 0,
+ .content_type = FHP_CONTENT_TYPE_NONE,
};
fhp_err_t
@@ -884,3 +885,8 @@ uint64_t
fhp_ctx_get_content_length(fhp_ctx_t * const ctx) {
return ctx->content_length;
}
+
+fhp_content_type_t
+fhp_ctx_get_content_type(fhp_ctx_t * const ctx) {
+ return ctx->content_type;
+}