summaryrefslogtreecommitdiffstats
path: root/src/core.h
diff options
context:
space:
mode:
authortiptorrent development team <tiptorrent@soleta.eu>2021-09-17 16:45:52 +0200
committertiptorrent development team <tiptorrent@soleta.eu>2021-09-29 15:48:43 +0200
commit16cc92dab608a3c83d9c1baa4dbdca307da12c9c (patch)
tree9c2bd5d3a7697aeca3ef314898fae03047a0576e /src/core.h
parentdab82c806f35c671f87ea60087b19e3781b35a29 (diff)
allow to report that a client allows redirection with POST method
If clients sends POST /test, it notifies the server that it is available for receive redirections from file 'test'. Test it with wget: wget --post-data '' http://localhost:9999/TEST -O /dev/null
Diffstat (limited to 'src/core.h')
-rw-r--r--src/core.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core.h b/src/core.h
index 7d6d403..9da9340 100644
--- a/src/core.h
+++ b/src/core.h
@@ -29,6 +29,7 @@ enum tip_client_state {
enum tip_http_method {
TIP_METHOD_GET = 0,
TIP_METHOD_HEAD,
+ TIP_METHOD_POST,
};
struct tip_client {
@@ -69,6 +70,8 @@ static inline bool tip_client_large_file(const struct tip_client *cli)
void tip_client_pending(struct tip_client *cli);
bool tip_client_redirect(struct tip_client *cli);
+int tip_client_redirect_create(const struct tip_client *cli);
+void tip_client_activate_pending(void);
extern struct ev_loop *tip_main_loop;