From 31a23ff4d20d7b89d3284eaecd34cd794d9738c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=EA=A6=AB=EA=A6=B6=EA=A6=8F=EA=A7=80=EA=A6=A6?= =?UTF-8?q?=EA=A6=BF=EA=A6=A7=EA=A6=AE=EA=A6=91=EA=A6=A9=EA=A6=AD=EA=A7=80?= Date: Mon, 1 Aug 2022 14:21:35 +0800 Subject: No curl call in Anteraja implementation --- anteraja.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/anteraja.c b/anteraja.c index 3706f2e..88172b4 100644 --- a/anteraja.c +++ b/anteraja.c @@ -64,10 +64,12 @@ const char **anteraja_init(char *provisions[]) prefix = malloc(strlen(provisions[PREFIX]) + 1); strcpy(prefix, provisions[PREFIX]); } - shipping->headers = curl_slist_append(shipping->headers, "Content-Type:application/json"); static const char *status_trail[] = { "status", NULL }; shipping->status_trail = status_trail; - static const char *fields[] = { "access-key-id", "secret-access-key", NULL }; + /* Base path is already set at this point, + so the slot can be used for the content type header. */ + provisions[BASE_PATH] = "application/json"; + static const char *fields[] = { "access-key-id", "secret-access-key", "Content-Type" }; return fields; } -- cgit v1.2.3