From 6cbc0f817066b8bbab84a9be466223652b628d42 Mon Sep 17 00:00:00 2001 From: ame Date: Mon, 26 Aug 2024 22:33:07 -0500 Subject: initial param matching --- src/net/util.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/net/util.h') diff --git a/src/net/util.h b/src/net/util.h index d723b6f..ea7c294 100644 --- a/src/net/util.h +++ b/src/net/util.h @@ -45,3 +45,5 @@ void http_code(int code, char* code_det); void client_fd_errors(int client_fd); int content_disposition(str* src, parray_t** _dest); + +parray_t* route_match(parray_t* paths, char* path); -- cgit v1.2.3 From f605f194eb45235989fc5ec91505201498834f24 Mon Sep 17 00:00:00 2001 From: amelia squires Date: Thu, 29 Aug 2024 00:10:05 -0500 Subject: should be working + tests --- src/net/util.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/net/util.h') diff --git a/src/net/util.h b/src/net/util.h index ea7c294..17a99ac 100644 --- a/src/net/util.h +++ b/src/net/util.h @@ -47,3 +47,6 @@ void client_fd_errors(int client_fd); int content_disposition(str* src, parray_t** _dest); parray_t* route_match(parray_t* paths, char* path); + +int match_param(char* path, char* match, parray_t* arr); + -- cgit v1.2.3 From 3bdf71c456a905607cb597ccc515bb222f86321d Mon Sep 17 00:00:00 2001 From: amelia squires Date: Wed, 4 Sep 2024 01:17:25 -0500 Subject: add to server, and fix leaks --- src/net/util.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/net/util.h') diff --git a/src/net/util.h b/src/net/util.h index 17a99ac..98d4d93 100644 --- a/src/net/util.h +++ b/src/net/util.h @@ -1,5 +1,5 @@ #include "common.h" - +#include "../types/larray.h" /** * @brief calls recv into buffer until everything is read * @@ -46,7 +46,7 @@ void client_fd_errors(int client_fd); int content_disposition(str* src, parray_t** _dest); -parray_t* route_match(parray_t* paths, char* path); +parray_t* route_match(parray_t* paths, char* path, larray_t** params); int match_param(char* path, char* match, parray_t* arr); -- cgit v1.2.3