summaryrefslogtreecommitdiffstats
path: root/src/aclk/https_client.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/aclk/https_client.h (renamed from aclk/https_client.h)13
1 files changed, 7 insertions, 6 deletions
diff --git a/aclk/https_client.h b/src/aclk/https_client.h
index 0b97fbb02..bc5ca30b8 100644
--- a/aclk/https_client.h
+++ b/src/aclk/https_client.h
@@ -5,13 +5,14 @@
#include "libnetdata/libnetdata.h"
-#include "mqtt_websockets/c-rbuf/include/ringbuffer.h"
-#include "mqtt_websockets/c_rhash/include/c_rhash.h"
+#include "mqtt_websockets/c-rbuf/cringbuffer.h"
+#include "mqtt_websockets/c_rhash/c_rhash.h"
typedef enum http_req_type {
HTTP_REQ_GET = 0,
HTTP_REQ_POST,
- HTTP_REQ_CONNECT
+ HTTP_REQ_CONNECT,
+ HTTP_REQ_INVALID
} http_req_type_t;
typedef struct {
@@ -56,7 +57,6 @@ int url_parse(const char *url, url_t *parsed);
void url_t_destroy(url_t *url);
void https_req_response_free(https_req_response_t *res);
-void https_req_response_init(https_req_response_t *res);
#define HTTPS_REQ_RESPONSE_T_INITIALIZER \
{ \
@@ -83,7 +83,8 @@ int https_request(https_req_t *request, https_req_response_t *response);
// we expose previously internal parser as this is usefull also from
// other parts of the code
enum http_parse_state {
- HTTP_PARSE_INITIAL = 0,
+ HTTP_PARSE_PROXY_CONNECT = 0,
+ HTTP_PARSE_INITIAL,
HTTP_PARSE_HEADERS,
HTTP_PARSE_CONTENT
};
@@ -119,7 +120,7 @@ typedef struct {
size_t chunk_got;
} http_parse_ctx;
-void http_parse_ctx_create(http_parse_ctx *ctx);
+void http_parse_ctx_create(http_parse_ctx *ctx, enum http_parse_state parse_state);
void http_parse_ctx_destroy(http_parse_ctx *ctx);
typedef enum {